Giter VIP home page Giter VIP logo

Comments (2)

nikbpetrov avatar nikbpetrov commented on June 9, 2024

Not sure what the problem is here. This is not even replicable as you don't provide the questions. Are you trying to say that your questions' text is too long? These will get wrapped up and displayed as paragraphs so the scroll bar will eventually be on the entire page. Likewise, if you have too many options in the labels of your questions, these won't expand more than the width of the parent (set to 95% by default via .jspsych-content).

If you want to create a defined box for each question of, say, height 200px and add a scroll bar to that box, that's a different story, though not only is it difficult but also not very user-friendly in my opinion.

from jspsych.

Shaobin-Jiang avatar Shaobin-Jiang commented on June 9, 2024

First, DO please provide a replicable code piece...

About your question, of course the scroll bar would not appear because your are setting the overflow-y on an element that does not take up any space, and you might want to set overflow-y on whatever element you want a scroll bar for. If, say, you want a vertical scroll bar on your preamble, you ought to wrap these paragraphs up with an element like div and apply overflow-y to that.

var pid5_questionaire = {
    type: jsPsychSurveyLikert,
    questions: [],
    randomize_question_order: true,
    preamble:
        "<div style='overflow-y: scroll;'><p></p>" +
        "<p><b>About yourself...</b></p>" +
        "<p>Below is a list of things different people might say about themselves. Please select the response that best describes you.</p></div>",
    require_movement: false,
    slider_width: 700,
    data: {
        screen: "questionnaire",
    },
}

I might as well give you one piece of advice: take some time to learn the basics of HTML and CSS. Trust me, you are not going to like rummaging through this kind of bugs without at least having a certain grasp of these two languages.

from jspsych.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.