|  | 
| 4 | 4 | 
 | 
| 5 | 5 | app_ui = ui.page_fluid( | 
| 6 | 6 |     ui.panel_title("Changing the values of inputs from the server"), | 
| 7 |  | -    ui.row( | 
| 8 |  | -        ui.column( | 
| 9 |  | -            4, | 
| 10 |  | -            ui.panel_well( | 
| 11 |  | -                ui.tags.h4("These inputs control the other inputs on the page"), | 
| 12 |  | -                ui.input_text( | 
| 13 |  | -                    "control_label", "This controls some of the labels:", "LABEL TEXT" | 
| 14 |  | -                ), | 
| 15 |  | -                ui.input_slider( | 
| 16 |  | -                    "control_num", "This controls values:", min=1, max=20, value=15 | 
| 17 |  | -                ), | 
|  | 7 | +    ui.layout_columns( | 
|  | 8 | +        ui.card( | 
|  | 9 | +            ui.card_header("These inputs control the other inputs on the page"), | 
|  | 10 | +            ui.input_text( | 
|  | 11 | +                "control_label", "This controls some of the labels:", "LABEL TEXT" | 
|  | 12 | +            ), | 
|  | 13 | +            ui.input_slider( | 
|  | 14 | +                "control_num", "This controls values:", min=1, max=20, value=15 | 
| 18 | 15 |             ), | 
| 19 | 16 |         ), | 
| 20 |  | -        ui.column( | 
| 21 |  | -            4, | 
| 22 |  | -            ui.panel_well( | 
| 23 |  | -                ui.tags.h4("These inputs are controlled by the other inputs"), | 
| 24 |  | -                ui.input_text("inText", "Text input:", value="start text"), | 
| 25 |  | -                ui.input_numeric( | 
| 26 |  | -                    "inNumber", "Number input:", min=1, max=20, value=5, step=0.5 | 
| 27 |  | -                ), | 
| 28 |  | -                ui.input_numeric( | 
| 29 |  | -                    "inNumber2", "Number input 2:", min=1, max=20, value=5, step=0.5 | 
| 30 |  | -                ), | 
| 31 |  | -                ui.input_slider("inSlider", "Slider input:", min=1, max=20, value=15), | 
| 32 |  | -                ui.input_slider( | 
| 33 |  | -                    "inSlider2", "Slider input 2:", min=1, max=20, value=(5, 15) | 
| 34 |  | -                ), | 
| 35 |  | -                ui.input_slider( | 
| 36 |  | -                    "inSlider3", "Slider input 3:", min=1, max=20, value=(5, 15) | 
| 37 |  | -                ), | 
| 38 |  | -                ui.input_date("inDate", "Date input:"), | 
| 39 |  | -                ui.input_date_range("inDateRange", "Date range input:"), | 
|  | 17 | +        ui.card( | 
|  | 18 | +            ui.card_header("These inputs are controlled by the other inputs"), | 
|  | 19 | +            ui.input_text("inText", "Text input:", value="start text"), | 
|  | 20 | +            ui.input_numeric( | 
|  | 21 | +                "inNumber", "Number input:", min=1, max=20, value=5, step=0.5 | 
|  | 22 | +            ), | 
|  | 23 | +            ui.input_numeric( | 
|  | 24 | +                "inNumber2", "Number input 2:", min=1, max=20, value=5, step=0.5 | 
|  | 25 | +            ), | 
|  | 26 | +            ui.input_slider("inSlider", "Slider input:", min=1, max=20, value=15), | 
|  | 27 | +            ui.input_slider( | 
|  | 28 | +                "inSlider2", "Slider input 2:", min=1, max=20, value=(5, 15) | 
|  | 29 | +            ), | 
|  | 30 | +            ui.input_slider( | 
|  | 31 | +                "inSlider3", "Slider input 3:", min=1, max=20, value=(5, 15) | 
| 40 | 32 |             ), | 
|  | 33 | +            ui.input_date("inDate", "Date input:"), | 
|  | 34 | +            ui.input_date_range("inDateRange", "Date range input:"), | 
| 41 | 35 |         ), | 
| 42 |  | -        ui.column( | 
| 43 |  | -            4, | 
| 44 |  | -            ui.panel_well( | 
| 45 |  | -                ui.input_checkbox("inCheckbox", "Checkbox input", value=False), | 
| 46 |  | -                ui.input_checkbox_group( | 
| 47 |  | -                    "inCheckboxGroup", | 
| 48 |  | -                    "Checkbox group input:", | 
| 49 |  | -                    { | 
| 50 |  | -                        "option1": "label 1", | 
| 51 |  | -                        "option2": "label 2", | 
| 52 |  | -                    }, | 
| 53 |  | -                ), | 
| 54 |  | -                ui.input_radio_buttons( | 
| 55 |  | -                    "inRadio", | 
| 56 |  | -                    "Radio buttons:", | 
| 57 |  | -                    { | 
| 58 |  | -                        "option1": "label 1", | 
| 59 |  | -                        "option2": "label 2", | 
| 60 |  | -                    }, | 
| 61 |  | -                ), | 
| 62 |  | -                ui.input_select( | 
| 63 |  | -                    "inSelect", | 
| 64 |  | -                    "Select input:", | 
| 65 |  | -                    { | 
| 66 |  | -                        "option1": "label 1", | 
| 67 |  | -                        "option2": "label 2", | 
| 68 |  | -                    }, | 
| 69 |  | -                ), | 
| 70 |  | -                ui.input_select( | 
| 71 |  | -                    "inSelect2", | 
| 72 |  | -                    "Select input 2:", | 
| 73 |  | -                    { | 
| 74 |  | -                        "option1": "label 1", | 
| 75 |  | -                        "option2": "label 2", | 
| 76 |  | -                    }, | 
| 77 |  | -                    multiple=True, | 
| 78 |  | -                ), | 
|  | 36 | +        ui.card( | 
|  | 37 | +            ui.card_header("These inputs are updated by the server"), | 
|  | 38 | +            ui.input_checkbox("inCheckbox", "Checkbox input", value=False), | 
|  | 39 | +            ui.input_checkbox_group( | 
|  | 40 | +                "inCheckboxGroup", | 
|  | 41 | +                "Checkbox group input:", | 
|  | 42 | +                { | 
|  | 43 | +                    "option1": "label 1", | 
|  | 44 | +                    "option2": "label 2", | 
|  | 45 | +                }, | 
|  | 46 | +            ), | 
|  | 47 | +            ui.input_radio_buttons( | 
|  | 48 | +                "inRadio", | 
|  | 49 | +                "Radio buttons:", | 
|  | 50 | +                { | 
|  | 51 | +                    "option1": "label 1", | 
|  | 52 | +                    "option2": "label 2", | 
|  | 53 | +                }, | 
|  | 54 | +            ), | 
|  | 55 | +            ui.input_select( | 
|  | 56 | +                "inSelect", | 
|  | 57 | +                "Select input:", | 
|  | 58 | +                { | 
|  | 59 | +                    "option1": "label 1", | 
|  | 60 | +                    "option2": "label 2", | 
|  | 61 | +                }, | 
|  | 62 | +            ), | 
|  | 63 | +            ui.input_select( | 
|  | 64 | +                "inSelect2", | 
|  | 65 | +                "Select input 2:", | 
|  | 66 | +                { | 
|  | 67 | +                    "option1": "label 1", | 
|  | 68 | +                    "option2": "label 2", | 
|  | 69 | +                }, | 
|  | 70 | +                multiple=True, | 
| 79 | 71 |             ), | 
| 80 | 72 |             ui.navset_tab( | 
| 81 | 73 |                 ui.nav_panel("panel1", ui.h2("This is the first panel.")), | 
|  | 
0 commit comments