primevue 3.15.0 → 3.16.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/autocomplete/AutoComplete.d.ts +182 -38
- package/autocomplete/AutoComplete.vue +636 -342
- package/autocomplete/autocomplete.cjs.js +745 -416
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.esm.js +747 -418
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +745 -416
- package/autocomplete/autocomplete.min.js +1 -1
- package/button/Button.vue +4 -1
- package/button/button.cjs.js +5 -1
- package/button/button.cjs.min.js +1 -1
- package/button/button.esm.js +5 -1
- package/button/button.esm.min.js +1 -1
- package/button/button.js +5 -1
- package/button/button.min.js +1 -1
- package/calendar/Calendar.d.ts +51 -12
- package/calendar/Calendar.vue +259 -114
- package/calendar/calendar.cjs.js +414 -220
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.esm.js +415 -221
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +414 -220
- package/calendar/calendar.min.js +1 -1
- package/carousel/Carousel.vue +25 -0
- package/carousel/carousel.cjs.js +25 -0
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +25 -0
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +25 -0
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/CascadeSelect.d.ts +97 -17
- package/cascadeselect/CascadeSelect.vue +560 -135
- package/cascadeselect/CascadeSelectSub.vue +48 -129
- package/cascadeselect/cascadeselect.cjs.js +670 -306
- package/cascadeselect/cascadeselect.cjs.min.js +1 -1
- package/cascadeselect/cascadeselect.esm.js +672 -308
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +670 -306
- package/cascadeselect/cascadeselect.min.js +1 -1
- package/checkbox/Checkbox.d.ts +40 -4
- package/checkbox/Checkbox.vue +50 -13
- package/checkbox/checkbox.cjs.js +64 -23
- package/checkbox/checkbox.cjs.min.js +1 -1
- package/checkbox/checkbox.esm.js +65 -24
- package/checkbox/checkbox.esm.min.js +1 -1
- package/checkbox/checkbox.js +64 -23
- package/checkbox/checkbox.min.js +1 -1
- package/chips/Chips.d.ts +36 -12
- package/chips/Chips.vue +116 -22
- package/chips/chips.cjs.js +149 -37
- package/chips/chips.cjs.min.js +1 -1
- package/chips/chips.esm.js +150 -38
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +150 -39
- package/chips/chips.min.js +1 -1
- package/colorpicker/ColorPicker.d.ts +3 -6
- package/colorpicker/ColorPicker.vue +1 -5
- package/colorpicker/colorpicker.cjs.js +2 -7
- package/colorpicker/colorpicker.cjs.min.js +1 -1
- package/colorpicker/colorpicker.esm.js +2 -7
- package/colorpicker/colorpicker.esm.min.js +1 -1
- package/colorpicker/colorpicker.js +2 -7
- package/colorpicker/colorpicker.min.js +1 -1
- package/column/Column.d.ts +4 -0
- package/column/Column.vue +4 -0
- package/column/column.cjs.js +4 -0
- package/column/column.cjs.min.js +1 -1
- package/column/column.esm.js +4 -0
- package/column/column.esm.min.js +1 -1
- package/column/column.js +4 -0
- package/column/column.min.js +1 -1
- package/config/PrimeVue.d.ts +42 -0
- package/config/config.cjs.js +35 -4
- package/config/config.cjs.min.js +1 -1
- package/config/config.esm.js +35 -4
- package/config/config.esm.min.js +1 -1
- package/config/config.js +35 -4
- package/config/config.min.js +1 -1
- package/confirmdialog/ConfirmDialog.vue +4 -1
- package/confirmdialog/confirmdialog.cjs.js +6 -2
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.esm.js +6 -2
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +6 -2
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/contextmenu/ContextMenu.d.ts +1 -1
- package/contextmenu/ContextMenuSub.vue +3 -3
- package/contextmenu/contextmenu.cjs.js +14 -8
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.esm.js +15 -9
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +14 -8
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +1128 -772
- package/core/core.min.js +12 -12
- package/datatable/BodyCell.vue +11 -2
- package/datatable/DataTable.vue +23 -2
- package/datatable/datatable.cjs.js +34 -4
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.esm.js +34 -4
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +34 -4
- package/datatable/datatable.min.js +1 -1
- package/dialog/Dialog.d.ts +5 -1
- package/dropdown/Dropdown.d.ts +92 -38
- package/dropdown/Dropdown.vue +538 -399
- package/dropdown/dropdown.cjs.js +657 -486
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.esm.js +659 -488
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +657 -486
- package/dropdown/dropdown.min.js +1 -1
- package/editor/Editor.d.ts +32 -0
- package/editor/Editor.vue +15 -1
- package/editor/editor.cjs.js +15 -1
- package/editor/editor.cjs.min.js +1 -1
- package/editor/editor.esm.js +15 -1
- package/editor/editor.esm.min.js +1 -1
- package/editor/editor.js +15 -1
- package/editor/editor.min.js +1 -1
- package/inputmask/InputMask.vue +9 -6
- package/inputmask/inputmask.cjs.js +14 -6
- package/inputmask/inputmask.cjs.min.js +1 -1
- package/inputmask/inputmask.esm.js +15 -7
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +14 -6
- package/inputmask/inputmask.min.js +1 -1
- package/inputnumber/InputNumber.d.ts +31 -7
- package/inputnumber/InputNumber.vue +53 -20
- package/inputnumber/inputnumber.cjs.js +75 -29
- package/inputnumber/inputnumber.cjs.min.js +1 -1
- package/inputnumber/inputnumber.esm.js +76 -30
- package/inputnumber/inputnumber.esm.min.js +1 -1
- package/inputnumber/inputnumber.js +75 -29
- package/inputnumber/inputnumber.min.js +1 -1
- package/inputswitch/InputSwitch.d.ts +24 -8
- package/inputswitch/InputSwitch.vue +27 -12
- package/inputswitch/inputswitch.cjs.js +38 -20
- package/inputswitch/inputswitch.cjs.min.js +1 -1
- package/inputswitch/inputswitch.esm.js +39 -21
- package/inputswitch/inputswitch.esm.min.js +1 -1
- package/inputswitch/inputswitch.js +38 -20
- package/inputswitch/inputswitch.min.js +1 -1
- package/inputtext/InputText.vue +1 -2
- package/inputtext/inputtext.cjs.js +3 -4
- package/inputtext/inputtext.cjs.min.js +1 -1
- package/inputtext/inputtext.esm.js +4 -5
- package/inputtext/inputtext.esm.min.js +1 -1
- package/inputtext/inputtext.js +3 -4
- package/inputtext/inputtext.min.js +1 -1
- package/knob/Knob.d.ts +12 -0
- package/knob/Knob.vue +62 -2
- package/knob/knob.cjs.js +73 -5
- package/knob/knob.cjs.min.js +1 -1
- package/knob/knob.esm.js +73 -5
- package/knob/knob.esm.min.js +1 -1
- package/knob/knob.js +73 -5
- package/knob/knob.min.js +1 -1
- package/listbox/Listbox.d.ts +53 -7
- package/listbox/Listbox.vue +500 -135
- package/listbox/listbox.cjs.js +597 -193
- package/listbox/listbox.cjs.min.js +1 -1
- package/listbox/listbox.esm.js +599 -195
- package/listbox/listbox.esm.min.js +1 -1
- package/listbox/listbox.js +597 -193
- package/listbox/listbox.min.js +1 -1
- package/menu/Menu.d.ts +1 -1
- package/menu/Menuitem.vue +2 -2
- package/menu/menu.cjs.js +12 -6
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.esm.js +13 -7
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +12 -6
- package/menu/menu.min.js +1 -1
- package/menubar/MenubarSub.vue +3 -3
- package/menubar/menubar.cjs.js +14 -8
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +15 -9
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +14 -8
- package/menubar/menubar.min.js +1 -1
- package/menuitem/MenuItem.d.ts +1 -1
- package/multiselect/MultiSelect.d.ts +111 -51
- package/multiselect/MultiSelect.vue +629 -338
- package/multiselect/multiselect.cjs.js +748 -428
- package/multiselect/multiselect.cjs.min.js +1 -1
- package/multiselect/multiselect.esm.js +750 -430
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +748 -428
- package/multiselect/multiselect.min.js +1 -1
- package/overlaypanel/OverlayPanel.d.ts +1 -1
- package/overlaypanel/OverlayPanel.vue +14 -2
- package/overlaypanel/overlaypanel.cjs.js +14 -2
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.esm.js +14 -2
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +14 -2
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/package.json +2 -2
- package/paginator/Paginator.d.ts +2 -2
- package/password/Password.d.ts +36 -8
- package/password/Password.vue +50 -14
- package/password/password.cjs.js +69 -24
- package/password/password.cjs.min.js +1 -1
- package/password/password.esm.js +71 -26
- package/password/password.esm.min.js +1 -1
- package/password/password.js +69 -24
- package/password/password.min.js +1 -1
- package/picklist/PickList.d.ts +8 -0
- package/picklist/PickList.vue +10 -2
- package/picklist/picklist.cjs.js +68 -50
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.esm.js +69 -51
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +68 -50
- package/picklist/picklist.min.js +1 -1
- package/portal/Portal.d.ts +1 -1
- package/radiobutton/RadioButton.d.ts +28 -4
- package/radiobutton/RadioButton.vue +36 -11
- package/radiobutton/radiobutton.cjs.js +49 -23
- package/radiobutton/radiobutton.cjs.min.js +1 -1
- package/radiobutton/radiobutton.esm.js +50 -24
- package/radiobutton/radiobutton.esm.min.js +1 -1
- package/radiobutton/radiobutton.js +49 -23
- package/radiobutton/radiobutton.min.js +1 -1
- package/rating/Rating.d.ts +4 -0
- package/rating/Rating.vue +61 -7
- package/rating/rating.cjs.js +90 -16
- package/rating/rating.cjs.min.js +1 -1
- package/rating/rating.esm.js +91 -17
- package/rating/rating.esm.min.js +1 -1
- package/rating/rating.js +90 -16
- package/rating/rating.min.js +1 -1
- package/resources/primevue.css +8 -0
- package/resources/primevue.min.css +1 -1
- package/resources/themes/arya-blue/theme.css +82 -40
- package/resources/themes/arya-green/theme.css +82 -40
- package/resources/themes/arya-orange/theme.css +82 -40
- package/resources/themes/arya-purple/theme.css +82 -40
- package/resources/themes/bootstrap4-dark-blue/theme.css +82 -40
- package/resources/themes/bootstrap4-dark-purple/theme.css +82 -40
- package/resources/themes/bootstrap4-light-blue/theme.css +82 -40
- package/resources/themes/bootstrap4-light-purple/theme.css +82 -40
- package/resources/themes/fluent-light/theme.css +82 -40
- package/resources/themes/lara-dark-blue/theme.css +82 -40
- package/resources/themes/lara-dark-indigo/theme.css +82 -40
- package/resources/themes/lara-dark-purple/theme.css +82 -40
- package/resources/themes/lara-dark-teal/theme.css +82 -40
- package/resources/themes/lara-light-blue/theme.css +82 -40
- package/resources/themes/lara-light-indigo/theme.css +82 -40
- package/resources/themes/lara-light-purple/theme.css +82 -40
- package/resources/themes/lara-light-teal/theme.css +82 -40
- package/resources/themes/luna-amber/theme.css +82 -40
- package/resources/themes/luna-blue/theme.css +82 -40
- package/resources/themes/luna-green/theme.css +82 -40
- package/resources/themes/luna-pink/theme.css +82 -40
- package/resources/themes/md-dark-deeppurple/theme.css +82 -40
- package/resources/themes/md-dark-indigo/theme.css +82 -40
- package/resources/themes/md-light-deeppurple/theme.css +82 -40
- package/resources/themes/md-light-indigo/theme.css +82 -40
- package/resources/themes/mdc-dark-deeppurple/theme.css +82 -40
- package/resources/themes/mdc-dark-indigo/theme.css +82 -40
- package/resources/themes/mdc-light-deeppurple/theme.css +82 -40
- package/resources/themes/mdc-light-indigo/theme.css +82 -40
- package/resources/themes/nova/theme.css +82 -40
- package/resources/themes/nova-accent/theme.css +82 -40
- package/resources/themes/nova-alt/theme.css +82 -40
- package/resources/themes/nova-vue/theme.css +82 -40
- package/resources/themes/rhea/theme.css +82 -40
- package/resources/themes/saga-blue/theme.css +82 -40
- package/resources/themes/saga-green/theme.css +82 -40
- package/resources/themes/saga-orange/theme.css +82 -40
- package/resources/themes/saga-purple/theme.css +82 -40
- package/resources/themes/tailwind-light/theme.css +82 -40
- package/resources/themes/vela-blue/theme.css +82 -40
- package/resources/themes/vela-green/theme.css +82 -40
- package/resources/themes/vela-orange/theme.css +82 -40
- package/resources/themes/vela-purple/theme.css +82 -40
- package/ripple/ripple.cjs.js +1 -0
- package/ripple/ripple.cjs.min.js +1 -1
- package/ripple/ripple.esm.js +1 -0
- package/ripple/ripple.esm.min.js +1 -1
- package/ripple/ripple.js +1 -0
- package/ripple/ripple.min.js +1 -1
- package/selectbutton/SelectButton.d.ts +6 -2
- package/selectbutton/SelectButton.vue +89 -12
- package/selectbutton/selectbutton.cjs.js +97 -22
- package/selectbutton/selectbutton.cjs.min.js +1 -1
- package/selectbutton/selectbutton.esm.js +99 -24
- package/selectbutton/selectbutton.esm.min.js +1 -1
- package/selectbutton/selectbutton.js +97 -22
- package/selectbutton/selectbutton.min.js +1 -1
- package/slider/Slider.d.ts +9 -1
- package/slider/Slider.vue +50 -34
- package/slider/slider.cjs.js +59 -38
- package/slider/slider.cjs.min.js +1 -1
- package/slider/slider.esm.js +59 -38
- package/slider/slider.esm.min.js +1 -1
- package/slider/slider.js +59 -38
- package/slider/slider.min.js +1 -1
- package/splitbutton/SplitButton.d.ts +1 -1
- package/splitter/Splitter.vue +30 -1
- package/splitter/splitter.cjs.js +30 -1
- package/splitter/splitter.cjs.min.js +1 -1
- package/splitter/splitter.esm.js +30 -1
- package/splitter/splitter.esm.min.js +1 -1
- package/splitter/splitter.js +30 -1
- package/splitter/splitter.min.js +1 -1
- package/textarea/Textarea.vue +1 -2
- package/textarea/textarea.cjs.js +3 -5
- package/textarea/textarea.cjs.min.js +1 -1
- package/textarea/textarea.esm.js +4 -6
- package/textarea/textarea.esm.min.js +1 -1
- package/textarea/textarea.js +3 -5
- package/textarea/textarea.min.js +1 -1
- package/tieredmenu/TieredMenu.d.ts +1 -1
- package/tieredmenu/TieredMenuSub.vue +3 -3
- package/tieredmenu/tieredmenu.cjs.js +14 -8
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.esm.js +15 -9
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +14 -8
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/Timeline.d.ts +10 -1
- package/timeline/Timeline.vue +1 -1
- package/timeline/timeline.cjs.js +5 -1
- package/timeline/timeline.cjs.min.js +1 -1
- package/timeline/timeline.esm.js +5 -1
- package/timeline/timeline.esm.min.js +1 -1
- package/timeline/timeline.js +5 -1
- package/timeline/timeline.min.js +1 -1
- package/togglebutton/ToggleButton.d.ts +42 -0
- package/togglebutton/ToggleButton.vue +44 -7
- package/togglebutton/togglebutton.cjs.js +59 -13
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.esm.js +60 -14
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +59 -13
- package/togglebutton/togglebutton.min.js +1 -1
- package/tooltip/tooltip.cjs.js +20 -11
- package/tooltip/tooltip.cjs.min.js +1 -1
- package/tooltip/tooltip.esm.js +21 -12
- package/tooltip/tooltip.esm.min.js +1 -1
- package/tooltip/tooltip.js +20 -11
- package/tooltip/tooltip.min.js +1 -1
- package/tree/Tree.vue +5 -1
- package/tree/TreeNode.vue +20 -19
- package/tree/tree.cjs.js +47 -32
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.esm.js +47 -32
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +47 -32
- package/tree/tree.min.js +1 -1
- package/treeselect/TreeSelect.d.ts +26 -10
- package/treeselect/TreeSelect.vue +52 -29
- package/treeselect/treeselect.cjs.js +74 -41
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.esm.js +76 -43
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +74 -41
- package/treeselect/treeselect.min.js +1 -1
- package/tristatecheckbox/TriStateCheckbox.d.ts +20 -4
- package/tristatecheckbox/TriStateCheckbox.vue +52 -15
- package/tristatecheckbox/tristatecheckbox.cjs.js +67 -26
- package/tristatecheckbox/tristatecheckbox.cjs.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.esm.js +68 -27
- package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.js +67 -26
- package/tristatecheckbox/tristatecheckbox.min.js +1 -1
- package/utils/Utils.d.ts +3 -2
- package/utils/utils.cjs.js +239 -173
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.esm.js +239 -173
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +239 -173
- package/utils/utils.min.js +1 -1
- package/vetur-attributes.json +612 -136
- package/vetur-tags.json +180 -59
- package/virtualscroller/VirtualScroller.d.ts +10 -0
- package/virtualscroller/VirtualScroller.vue +18 -17
- package/virtualscroller/virtualscroller.cjs.js +22 -20
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.esm.js +22 -20
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +22 -20
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +1745 -338
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("primevue/utils"),n=require("vue"),t={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,t){return this.dataKey?e.ObjectUtils.resolveFieldData(n,this.dataKey):t}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const i={class:"p-timeline-event-opposite"},l={class:"p-timeline-event-separator"},o=n.createElementVNode("div",{class:"p-timeline-event-marker"},null,-1),r=n.createElementVNode("div",{class:"p-timeline-event-connector"},null,-1),m={class:"p-timeline-event-content"};!function(e,n){void 0===n&&(n={});var t=n.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===t&&i.firstChild?i.insertBefore(l,i.firstChild):i.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),t.render=function(e,t,a,s,c,p){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.containerClass)},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,((t,s)=>(n.openBlock(),n.createElementBlock("div",{key:p.getKey(t,s),class:"p-timeline-event"},[n.createElementVNode("div",i,[n.renderSlot(e.$slots,"opposite",{item:t,index:s})]),n.createElementVNode("div",l,[n.renderSlot(e.$slots,"marker",{item:t,index:s},(()=>[o])),s!==a.value.length-1?n.renderSlot(e.$slots,"connector",{key:0},(()=>[r])):n.createCommentVNode("",!0)]),n.createElementVNode("div",m,[n.renderSlot(e.$slots,"content",{item:t,index:s})])])))),128))],2)},module.exports=t;
|
|
1
|
+
"use strict";var e=require("primevue/utils"),n=require("vue"),t={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,t){return this.dataKey?e.ObjectUtils.resolveFieldData(n,this.dataKey):t}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const i={class:"p-timeline-event-opposite"},l={class:"p-timeline-event-separator"},o=n.createElementVNode("div",{class:"p-timeline-event-marker"},null,-1),r=n.createElementVNode("div",{class:"p-timeline-event-connector"},null,-1),m={class:"p-timeline-event-content"};!function(e,n){void 0===n&&(n={});var t=n.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===t&&i.firstChild?i.insertBefore(l,i.firstChild):i.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),t.render=function(e,t,a,s,c,p){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.containerClass)},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,((t,s)=>(n.openBlock(),n.createElementBlock("div",{key:p.getKey(t,s),class:"p-timeline-event"},[n.createElementVNode("div",i,[n.renderSlot(e.$slots,"opposite",{item:t,index:s})]),n.createElementVNode("div",l,[n.renderSlot(e.$slots,"marker",{item:t,index:s},(()=>[o])),s!==a.value.length-1?n.renderSlot(e.$slots,"connector",{key:0,item:t,index:s},(()=>[r])):n.createCommentVNode("",!0)]),n.createElementVNode("div",m,[n.renderSlot(e.$slots,"content",{item:t,index:s})])])))),128))],2)},module.exports=t;
|
package/timeline/timeline.esm.js
CHANGED
|
@@ -60,7 +60,11 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
60
60
|
_hoisted_3
|
|
61
61
|
]),
|
|
62
62
|
(index !== ($props.value.length - 1))
|
|
63
|
-
? renderSlot(_ctx.$slots, "connector", {
|
|
63
|
+
? renderSlot(_ctx.$slots, "connector", {
|
|
64
|
+
key: 0,
|
|
65
|
+
item: item,
|
|
66
|
+
index: index
|
|
67
|
+
}, () => [
|
|
64
68
|
_hoisted_4
|
|
65
69
|
])
|
|
66
70
|
: createCommentVNode("", true)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ObjectUtils as e}from"primevue/utils";import{openBlock as n,createElementBlock as i,normalizeClass as t,Fragment as l,renderList as o,createElementVNode as r,renderSlot as m,createCommentVNode as a}from"vue";var s={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,i){return this.dataKey?e.resolveFieldData(n,this.dataKey):i}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const p={class:"p-timeline-event-opposite"},x={class:"p-timeline-event-separator"},c=r("div",{class:"p-timeline-event-marker"},null,-1),d=r("div",{class:"p-timeline-event-connector"},null,-1),v={class:"p-timeline-event-content"};!function(e,n){void 0===n&&(n={});var i=n.insertAt;if(e&&"undefined"!=typeof document){var t=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===i&&t.firstChild?t.insertBefore(l,t.firstChild):t.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),s.render=function(e,s,f,b,h,w){return n(),i("div",{class:t(w.containerClass)},[(n(!0),i(l,null,o(f.value,((t,l)=>(n(),i("div",{key:w.getKey(t,l),class:"p-timeline-event"},[r("div",p,[m(e.$slots,"opposite",{item:t,index:l})]),r("div",x,[m(e.$slots,"marker",{item:t,index:l},(()=>[c])),l!==f.value.length-1?m(e.$slots,"connector",{key:0},(()=>[d])):a("",!0)]),r("div",v,[m(e.$slots,"content",{item:t,index:l})])])))),128))],2)};export{s as default};
|
|
1
|
+
import{ObjectUtils as e}from"primevue/utils";import{openBlock as n,createElementBlock as i,normalizeClass as t,Fragment as l,renderList as o,createElementVNode as r,renderSlot as m,createCommentVNode as a}from"vue";var s={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,i){return this.dataKey?e.resolveFieldData(n,this.dataKey):i}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const p={class:"p-timeline-event-opposite"},x={class:"p-timeline-event-separator"},c=r("div",{class:"p-timeline-event-marker"},null,-1),d=r("div",{class:"p-timeline-event-connector"},null,-1),v={class:"p-timeline-event-content"};!function(e,n){void 0===n&&(n={});var i=n.insertAt;if(e&&"undefined"!=typeof document){var t=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===i&&t.firstChild?t.insertBefore(l,t.firstChild):t.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),s.render=function(e,s,f,b,h,w){return n(),i("div",{class:t(w.containerClass)},[(n(!0),i(l,null,o(f.value,((t,l)=>(n(),i("div",{key:w.getKey(t,l),class:"p-timeline-event"},[r("div",p,[m(e.$slots,"opposite",{item:t,index:l})]),r("div",x,[m(e.$slots,"marker",{item:t,index:l},(()=>[c])),l!==f.value.length-1?m(e.$slots,"connector",{key:0,item:t,index:l},(()=>[d])):a("",!0)]),r("div",v,[m(e.$slots,"content",{item:t,index:l})])])))),128))],2)};export{s as default};
|
package/timeline/timeline.js
CHANGED
|
@@ -61,7 +61,11 @@ this.primevue.timeline = (function (utils, vue) {
|
|
|
61
61
|
_hoisted_3
|
|
62
62
|
]),
|
|
63
63
|
(index !== ($props.value.length - 1))
|
|
64
|
-
? vue.renderSlot(_ctx.$slots, "connector", {
|
|
64
|
+
? vue.renderSlot(_ctx.$slots, "connector", {
|
|
65
|
+
key: 0,
|
|
66
|
+
item: item,
|
|
67
|
+
index: index
|
|
68
|
+
}, () => [
|
|
65
69
|
_hoisted_4
|
|
66
70
|
])
|
|
67
71
|
: vue.createCommentVNode("", true)
|
package/timeline/timeline.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primevue=this.primevue||{},this.primevue.timeline=function(e,n){"use strict";var t={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,t){return this.dataKey?e.ObjectUtils.resolveFieldData(n,this.dataKey):t}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const i={class:"p-timeline-event-opposite"},l={class:"p-timeline-event-separator"},o=n.createElementVNode("div",{class:"p-timeline-event-marker"},null,-1),r=n.createElementVNode("div",{class:"p-timeline-event-connector"},null,-1),m={class:"p-timeline-event-content"};return function(e,n){void 0===n&&(n={});var t=n.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===t&&i.firstChild?i.insertBefore(l,i.firstChild):i.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),t.render=function(e,t,a,s,c,p){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.containerClass)},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,((t,s)=>(n.openBlock(),n.createElementBlock("div",{key:p.getKey(t,s),class:"p-timeline-event"},[n.createElementVNode("div",i,[n.renderSlot(e.$slots,"opposite",{item:t,index:s})]),n.createElementVNode("div",l,[n.renderSlot(e.$slots,"marker",{item:t,index:s},(()=>[o])),s!==a.value.length-1?n.renderSlot(e.$slots,"connector",{key:0},(()=>[r])):n.createCommentVNode("",!0)]),n.createElementVNode("div",m,[n.renderSlot(e.$slots,"content",{item:t,index:s})])])))),128))],2)},t}(primevue.utils,Vue);
|
|
1
|
+
this.primevue=this.primevue||{},this.primevue.timeline=function(e,n){"use strict";var t={name:"Timeline",props:{value:null,align:{mode:String,default:"left"},layout:{mode:String,default:"vertical"},dataKey:null},methods:{getKey(n,t){return this.dataKey?e.ObjectUtils.resolveFieldData(n,this.dataKey):t}},computed:{containerClass(){return["p-timeline p-component","p-timeline-"+this.align,"p-timeline-"+this.layout]}}};const i={class:"p-timeline-event-opposite"},l={class:"p-timeline-event-separator"},o=n.createElementVNode("div",{class:"p-timeline-event-marker"},null,-1),r=n.createElementVNode("div",{class:"p-timeline-event-connector"},null,-1),m={class:"p-timeline-event-content"};return function(e,n){void 0===n&&(n={});var t=n.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],l=document.createElement("style");l.type="text/css","top"===t&&i.firstChild?i.insertBefore(l,i.firstChild):i.appendChild(l),l.styleSheet?l.styleSheet.cssText=e:l.appendChild(document.createTextNode(e))}}("\n.p-timeline {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-left .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-left .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-right .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-right .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: reverse;\n -ms-flex-direction: row-reverse;\n flex-direction: row-reverse;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-opposite {\n text-align: right;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(odd) .p-timeline-event-content {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-opposite {\n text-align: left;\n}\n.p-timeline-vertical.p-timeline-alternate .p-timeline-event:nth-child(even) .p-timeline-event-content {\n text-align: right;\n}\n.p-timeline-event {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n min-height: 70px;\n}\n.p-timeline-event:last-child {\n min-height: 0;\n}\n.p-timeline-event-opposite {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-content {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n padding: 0 1rem;\n}\n.p-timeline-event-separator {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-timeline-event-marker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-item-align: baseline;\n align-self: baseline;\n}\n.p-timeline-event-connector {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n}\n.p-timeline-horizontal {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n.p-timeline-horizontal .p-timeline-event:last-child {\n -webkit-box-flex: 0;\n -ms-flex: 0;\n flex: 0;\n}\n.p-timeline-horizontal .p-timeline-event-separator {\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n}\n.p-timeline-horizontal .p-timeline-event-connector {\n width: 100%;\n}\n.p-timeline-bottom .p-timeline-event {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n.p-timeline-horizontal.p-timeline-alternate .p-timeline-event:nth-child(even) {\n -webkit-box-orient: vertical;\n -webkit-box-direction: reverse;\n -ms-flex-direction: column-reverse;\n flex-direction: column-reverse;\n}\n"),t.render=function(e,t,a,s,c,p){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.containerClass)},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,((t,s)=>(n.openBlock(),n.createElementBlock("div",{key:p.getKey(t,s),class:"p-timeline-event"},[n.createElementVNode("div",i,[n.renderSlot(e.$slots,"opposite",{item:t,index:s})]),n.createElementVNode("div",l,[n.renderSlot(e.$slots,"marker",{item:t,index:s},(()=>[o])),s!==a.value.length-1?n.renderSlot(e.$slots,"connector",{key:0,item:t,index:s},(()=>[r])):n.createCommentVNode("",!0)]),n.createElementVNode("div",m,[n.renderSlot(e.$slots,"content",{item:t,index:s})])])))),128))],2)},t}(primevue.utils,Vue);
|
|
@@ -31,6 +31,38 @@ export interface ToggleButtonProps {
|
|
|
31
31
|
* Default value is 'left'.
|
|
32
32
|
*/
|
|
33
33
|
iconPos?: ToggleButtonType;
|
|
34
|
+
/**
|
|
35
|
+
* When present, it specifies that the element should be disabled.
|
|
36
|
+
*/
|
|
37
|
+
disabled?: boolean | undefined;
|
|
38
|
+
/**
|
|
39
|
+
* Index of the element in tabbing order.
|
|
40
|
+
*/
|
|
41
|
+
tabindex?: string | undefined;
|
|
42
|
+
/**
|
|
43
|
+
* Identifier of the focus input to match a label defined for the chips.
|
|
44
|
+
*/
|
|
45
|
+
inputId?: string | undefined;
|
|
46
|
+
/**
|
|
47
|
+
* Style class of the input field.
|
|
48
|
+
*/
|
|
49
|
+
inputClass?: any | undefined;
|
|
50
|
+
/**
|
|
51
|
+
* Inline style of the input field.
|
|
52
|
+
*/
|
|
53
|
+
inputStyle?: any | undefined;
|
|
54
|
+
/**
|
|
55
|
+
* Uses to pass all properties of the HTMLInputElement to the focusable input element inside the component.
|
|
56
|
+
*/
|
|
57
|
+
inputProps?: HTMLInputElement | undefined;
|
|
58
|
+
/**
|
|
59
|
+
* Establishes relationships between the component and label(s) where its value should be one or more element IDs.
|
|
60
|
+
*/
|
|
61
|
+
'aria-labelledby'?: string | undefined;
|
|
62
|
+
/**
|
|
63
|
+
* Establishes a string value that labels the component.
|
|
64
|
+
*/
|
|
65
|
+
'aria-label'?: string | undefined;
|
|
34
66
|
}
|
|
35
67
|
|
|
36
68
|
export interface ToggleButtonSlots {
|
|
@@ -47,6 +79,16 @@ export declare type ToggleButtonEmits = {
|
|
|
47
79
|
* @param {Event} event - Browser event.
|
|
48
80
|
*/
|
|
49
81
|
'change': (event: Event) => void;
|
|
82
|
+
/**
|
|
83
|
+
* Callback to invoke when the component receives focus.
|
|
84
|
+
* @param {Event} event - Browser event.
|
|
85
|
+
*/
|
|
86
|
+
'focus': (event: Event) => void;
|
|
87
|
+
/**
|
|
88
|
+
* Callback to invoke when the component loses focus.
|
|
89
|
+
* @param {Event} event - Browser event.
|
|
90
|
+
*/
|
|
91
|
+
'blur': (event: Event) => void;
|
|
50
92
|
}
|
|
51
93
|
|
|
52
94
|
declare class ToggleButton extends ClassComponent<ToggleButtonProps, ToggleButtonSlots, ToggleButtonEmits> { }
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div :class="buttonClass" @click="onClick($event)"
|
|
2
|
+
<div :class="buttonClass" @click="onClick($event)" v-ripple>
|
|
3
|
+
<span class="p-hidden-accessible">
|
|
4
|
+
<input type="checkbox" role="switch" :id="inputId" :class="inputClass" :style="inputStyle" :checked="modelValue" :value="modelValue" :aria-labelledby="ariaLabelledby" :aria-label="ariaLabel"
|
|
5
|
+
@focus="onFocus($event)" @blur="onBlur($event)" v-bind="inputProps">
|
|
6
|
+
</span>
|
|
3
7
|
<span v-if="hasIcon" :class="iconClass"></span>
|
|
4
8
|
<span class="p-button-label">{{label}}</span>
|
|
5
9
|
</div>
|
|
@@ -10,24 +14,57 @@ import Ripple from 'primevue/ripple';
|
|
|
10
14
|
|
|
11
15
|
export default {
|
|
12
16
|
name: 'ToggleButton',
|
|
13
|
-
emits: ['update:modelValue', 'change'],
|
|
17
|
+
emits: ['update:modelValue', 'change', 'click', 'focus', 'blur'],
|
|
14
18
|
props: {
|
|
15
19
|
modelValue: Boolean,
|
|
16
20
|
onIcon: String,
|
|
17
21
|
offIcon: String,
|
|
18
|
-
onLabel:
|
|
19
|
-
|
|
22
|
+
onLabel: {
|
|
23
|
+
type: String,
|
|
24
|
+
default: 'Yes'
|
|
25
|
+
},
|
|
26
|
+
offLabel: {
|
|
27
|
+
type: String,
|
|
28
|
+
default: 'No'
|
|
29
|
+
},
|
|
20
30
|
iconPos: {
|
|
21
31
|
type: String,
|
|
22
32
|
default: 'left'
|
|
33
|
+
},
|
|
34
|
+
disabled: {
|
|
35
|
+
type: Boolean,
|
|
36
|
+
default: false
|
|
37
|
+
},
|
|
38
|
+
tabindex: {
|
|
39
|
+
type: Number,
|
|
40
|
+
default: null
|
|
41
|
+
},
|
|
42
|
+
inputId: null,
|
|
43
|
+
inputClass: null,
|
|
44
|
+
inputStyle: null,
|
|
45
|
+
inputProps: null,
|
|
46
|
+
'aria-labelledby': {
|
|
47
|
+
type: String,
|
|
48
|
+
default: null
|
|
49
|
+
},
|
|
50
|
+
'aria-label': {
|
|
51
|
+
type: String,
|
|
52
|
+
default: null
|
|
23
53
|
}
|
|
24
54
|
},
|
|
25
55
|
methods: {
|
|
26
56
|
onClick(event) {
|
|
27
|
-
if (!this
|
|
57
|
+
if (!this.disabled) {
|
|
28
58
|
this.$emit('update:modelValue', !this.modelValue);
|
|
29
59
|
this.$emit('change', event);
|
|
60
|
+
this.$emit('click', event);
|
|
30
61
|
}
|
|
62
|
+
},
|
|
63
|
+
onFocus(event) {
|
|
64
|
+
this.$emit('focus', event);
|
|
65
|
+
},
|
|
66
|
+
onBlur(event) {
|
|
67
|
+
this.$emit('blur', event);
|
|
31
68
|
}
|
|
32
69
|
},
|
|
33
70
|
computed: {
|
|
@@ -35,7 +72,7 @@ export default {
|
|
|
35
72
|
return {
|
|
36
73
|
'p-button p-togglebutton p-component': true,
|
|
37
74
|
'p-button-icon-only': this.hasIcon && !this.hasLabel,
|
|
38
|
-
'p-disabled': this
|
|
75
|
+
'p-disabled': this.disabled,
|
|
39
76
|
'p-highlight': this.modelValue === true
|
|
40
77
|
}
|
|
41
78
|
},
|
|
@@ -63,4 +100,4 @@ export default {
|
|
|
63
100
|
'ripple': Ripple
|
|
64
101
|
}
|
|
65
102
|
}
|
|
66
|
-
</script>
|
|
103
|
+
</script>
|
|
@@ -9,24 +9,57 @@ var Ripple__default = /*#__PURE__*/_interopDefaultLegacy(Ripple);
|
|
|
9
9
|
|
|
10
10
|
var script = {
|
|
11
11
|
name: 'ToggleButton',
|
|
12
|
-
emits: ['update:modelValue', 'change'],
|
|
12
|
+
emits: ['update:modelValue', 'change', 'click', 'focus', 'blur'],
|
|
13
13
|
props: {
|
|
14
14
|
modelValue: Boolean,
|
|
15
15
|
onIcon: String,
|
|
16
16
|
offIcon: String,
|
|
17
|
-
onLabel:
|
|
18
|
-
|
|
17
|
+
onLabel: {
|
|
18
|
+
type: String,
|
|
19
|
+
default: 'Yes'
|
|
20
|
+
},
|
|
21
|
+
offLabel: {
|
|
22
|
+
type: String,
|
|
23
|
+
default: 'No'
|
|
24
|
+
},
|
|
19
25
|
iconPos: {
|
|
20
26
|
type: String,
|
|
21
27
|
default: 'left'
|
|
28
|
+
},
|
|
29
|
+
disabled: {
|
|
30
|
+
type: Boolean,
|
|
31
|
+
default: false
|
|
32
|
+
},
|
|
33
|
+
tabindex: {
|
|
34
|
+
type: Number,
|
|
35
|
+
default: null
|
|
36
|
+
},
|
|
37
|
+
inputId: null,
|
|
38
|
+
inputClass: null,
|
|
39
|
+
inputStyle: null,
|
|
40
|
+
inputProps: null,
|
|
41
|
+
'aria-labelledby': {
|
|
42
|
+
type: String,
|
|
43
|
+
default: null
|
|
44
|
+
},
|
|
45
|
+
'aria-label': {
|
|
46
|
+
type: String,
|
|
47
|
+
default: null
|
|
22
48
|
}
|
|
23
49
|
},
|
|
24
50
|
methods: {
|
|
25
51
|
onClick(event) {
|
|
26
|
-
if (!this
|
|
52
|
+
if (!this.disabled) {
|
|
27
53
|
this.$emit('update:modelValue', !this.modelValue);
|
|
28
54
|
this.$emit('change', event);
|
|
55
|
+
this.$emit('click', event);
|
|
29
56
|
}
|
|
57
|
+
},
|
|
58
|
+
onFocus(event) {
|
|
59
|
+
this.$emit('focus', event);
|
|
60
|
+
},
|
|
61
|
+
onBlur(event) {
|
|
62
|
+
this.$emit('blur', event);
|
|
30
63
|
}
|
|
31
64
|
},
|
|
32
65
|
computed: {
|
|
@@ -34,7 +67,7 @@ var script = {
|
|
|
34
67
|
return {
|
|
35
68
|
'p-button p-togglebutton p-component': true,
|
|
36
69
|
'p-button-icon-only': this.hasIcon && !this.hasLabel,
|
|
37
|
-
'p-disabled': this
|
|
70
|
+
'p-disabled': this.disabled,
|
|
38
71
|
'p-highlight': this.modelValue === true
|
|
39
72
|
}
|
|
40
73
|
},
|
|
@@ -63,27 +96,40 @@ var script = {
|
|
|
63
96
|
}
|
|
64
97
|
};
|
|
65
98
|
|
|
66
|
-
const _hoisted_1 =
|
|
67
|
-
const _hoisted_2 =
|
|
99
|
+
const _hoisted_1 = { class: "p-hidden-accessible" };
|
|
100
|
+
const _hoisted_2 = ["id", "checked", "value", "aria-labelledby", "aria-label"];
|
|
101
|
+
const _hoisted_3 = { class: "p-button-label" };
|
|
68
102
|
|
|
69
103
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
70
104
|
const _directive_ripple = vue.resolveDirective("ripple");
|
|
71
105
|
|
|
72
106
|
return vue.withDirectives((vue.openBlock(), vue.createElementBlock("div", {
|
|
73
107
|
class: vue.normalizeClass($options.buttonClass),
|
|
74
|
-
onClick: _cache[
|
|
75
|
-
role: "checkbox",
|
|
76
|
-
"aria-checked": $props.modelValue,
|
|
77
|
-
tabindex: _ctx.$attrs.disabled ? null : '0'
|
|
108
|
+
onClick: _cache[2] || (_cache[2] = $event => ($options.onClick($event)))
|
|
78
109
|
}, [
|
|
110
|
+
vue.createElementVNode("span", _hoisted_1, [
|
|
111
|
+
vue.createElementVNode("input", vue.mergeProps({
|
|
112
|
+
type: "checkbox",
|
|
113
|
+
role: "switch",
|
|
114
|
+
id: $props.inputId,
|
|
115
|
+
class: $props.inputClass,
|
|
116
|
+
style: $props.inputStyle,
|
|
117
|
+
checked: $props.modelValue,
|
|
118
|
+
value: $props.modelValue,
|
|
119
|
+
"aria-labelledby": _ctx.ariaLabelledby,
|
|
120
|
+
"aria-label": _ctx.ariaLabel,
|
|
121
|
+
onFocus: _cache[0] || (_cache[0] = $event => ($options.onFocus($event))),
|
|
122
|
+
onBlur: _cache[1] || (_cache[1] = $event => ($options.onBlur($event)))
|
|
123
|
+
}, $props.inputProps), null, 16, _hoisted_2)
|
|
124
|
+
]),
|
|
79
125
|
($options.hasIcon)
|
|
80
126
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
81
127
|
key: 0,
|
|
82
128
|
class: vue.normalizeClass($options.iconClass)
|
|
83
129
|
}, null, 2))
|
|
84
130
|
: vue.createCommentVNode("", true),
|
|
85
|
-
vue.createElementVNode("span",
|
|
86
|
-
],
|
|
131
|
+
vue.createElementVNode("span", _hoisted_3, vue.toDisplayString($options.label), 1)
|
|
132
|
+
], 2)), [
|
|
87
133
|
[_directive_ripple]
|
|
88
134
|
])
|
|
89
135
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("primevue/ripple"),
|
|
1
|
+
"use strict";var e=require("primevue/ripple"),l=require("vue");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n={name:"ToggleButton",emits:["update:modelValue","change","click","focus","blur"],props:{modelValue:Boolean,onIcon:String,offIcon:String,onLabel:{type:String,default:"Yes"},offLabel:{type:String,default:"No"},iconPos:{type:String,default:"left"},disabled:{type:Boolean,default:!1},tabindex:{type:Number,default:null},inputId:null,inputClass:null,inputStyle:null,inputProps:null,"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},methods:{onClick(e){this.disabled||(this.$emit("update:modelValue",!this.modelValue),this.$emit("change",e),this.$emit("click",e))},onFocus(e){this.$emit("focus",e)},onBlur(e){this.$emit("blur",e)}},computed:{buttonClass(){return{"p-button p-togglebutton p-component":!0,"p-button-icon-only":this.hasIcon&&!this.hasLabel,"p-disabled":this.disabled,"p-highlight":!0===this.modelValue}},iconClass(){return[this.modelValue?this.onIcon:this.offIcon,"p-button-icon",{"p-button-icon-left":"left"===this.iconPos&&this.label,"p-button-icon-right":"right"===this.iconPos&&this.label}]},hasLabel(){return this.onLabel&&this.onLabel.length>0&&this.offLabel&&this.offLabel.length>0},hasIcon(){return this.onIcon&&this.onIcon.length>0&&this.offIcon&&this.offIcon.length>0},label(){return this.hasLabel?this.modelValue?this.onLabel:this.offLabel:" "}},directives:{ripple:t(e).default}};const o={class:"p-hidden-accessible"},i=["id","checked","value","aria-labelledby","aria-label"],a={class:"p-button-label"};n.render=function(e,t,n,s,u,r){const c=l.resolveDirective("ripple");return l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass(r.buttonClass),onClick:t[2]||(t[2]=e=>r.onClick(e))},[l.createElementVNode("span",o,[l.createElementVNode("input",l.mergeProps({type:"checkbox",role:"switch",id:n.inputId,class:n.inputClass,style:n.inputStyle,checked:n.modelValue,value:n.modelValue,"aria-labelledby":e.ariaLabelledby,"aria-label":e.ariaLabel,onFocus:t[0]||(t[0]=e=>r.onFocus(e)),onBlur:t[1]||(t[1]=e=>r.onBlur(e))},n.inputProps),null,16,i)]),r.hasIcon?(l.openBlock(),l.createElementBlock("span",{key:0,class:l.normalizeClass(r.iconClass)},null,2)):l.createCommentVNode("",!0),l.createElementVNode("span",a,l.toDisplayString(r.label),1)],2)),[[c]])},module.exports=n;
|
|
@@ -1,26 +1,59 @@
|
|
|
1
1
|
import Ripple from 'primevue/ripple';
|
|
2
|
-
import { resolveDirective, withDirectives, openBlock, createElementBlock, normalizeClass,
|
|
2
|
+
import { resolveDirective, withDirectives, openBlock, createElementBlock, normalizeClass, createElementVNode, mergeProps, createCommentVNode, toDisplayString } from 'vue';
|
|
3
3
|
|
|
4
4
|
var script = {
|
|
5
5
|
name: 'ToggleButton',
|
|
6
|
-
emits: ['update:modelValue', 'change'],
|
|
6
|
+
emits: ['update:modelValue', 'change', 'click', 'focus', 'blur'],
|
|
7
7
|
props: {
|
|
8
8
|
modelValue: Boolean,
|
|
9
9
|
onIcon: String,
|
|
10
10
|
offIcon: String,
|
|
11
|
-
onLabel:
|
|
12
|
-
|
|
11
|
+
onLabel: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: 'Yes'
|
|
14
|
+
},
|
|
15
|
+
offLabel: {
|
|
16
|
+
type: String,
|
|
17
|
+
default: 'No'
|
|
18
|
+
},
|
|
13
19
|
iconPos: {
|
|
14
20
|
type: String,
|
|
15
21
|
default: 'left'
|
|
22
|
+
},
|
|
23
|
+
disabled: {
|
|
24
|
+
type: Boolean,
|
|
25
|
+
default: false
|
|
26
|
+
},
|
|
27
|
+
tabindex: {
|
|
28
|
+
type: Number,
|
|
29
|
+
default: null
|
|
30
|
+
},
|
|
31
|
+
inputId: null,
|
|
32
|
+
inputClass: null,
|
|
33
|
+
inputStyle: null,
|
|
34
|
+
inputProps: null,
|
|
35
|
+
'aria-labelledby': {
|
|
36
|
+
type: String,
|
|
37
|
+
default: null
|
|
38
|
+
},
|
|
39
|
+
'aria-label': {
|
|
40
|
+
type: String,
|
|
41
|
+
default: null
|
|
16
42
|
}
|
|
17
43
|
},
|
|
18
44
|
methods: {
|
|
19
45
|
onClick(event) {
|
|
20
|
-
if (!this
|
|
46
|
+
if (!this.disabled) {
|
|
21
47
|
this.$emit('update:modelValue', !this.modelValue);
|
|
22
48
|
this.$emit('change', event);
|
|
49
|
+
this.$emit('click', event);
|
|
23
50
|
}
|
|
51
|
+
},
|
|
52
|
+
onFocus(event) {
|
|
53
|
+
this.$emit('focus', event);
|
|
54
|
+
},
|
|
55
|
+
onBlur(event) {
|
|
56
|
+
this.$emit('blur', event);
|
|
24
57
|
}
|
|
25
58
|
},
|
|
26
59
|
computed: {
|
|
@@ -28,7 +61,7 @@ var script = {
|
|
|
28
61
|
return {
|
|
29
62
|
'p-button p-togglebutton p-component': true,
|
|
30
63
|
'p-button-icon-only': this.hasIcon && !this.hasLabel,
|
|
31
|
-
'p-disabled': this
|
|
64
|
+
'p-disabled': this.disabled,
|
|
32
65
|
'p-highlight': this.modelValue === true
|
|
33
66
|
}
|
|
34
67
|
},
|
|
@@ -57,27 +90,40 @@ var script = {
|
|
|
57
90
|
}
|
|
58
91
|
};
|
|
59
92
|
|
|
60
|
-
const _hoisted_1 =
|
|
61
|
-
const _hoisted_2 =
|
|
93
|
+
const _hoisted_1 = { class: "p-hidden-accessible" };
|
|
94
|
+
const _hoisted_2 = ["id", "checked", "value", "aria-labelledby", "aria-label"];
|
|
95
|
+
const _hoisted_3 = { class: "p-button-label" };
|
|
62
96
|
|
|
63
97
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
64
98
|
const _directive_ripple = resolveDirective("ripple");
|
|
65
99
|
|
|
66
100
|
return withDirectives((openBlock(), createElementBlock("div", {
|
|
67
101
|
class: normalizeClass($options.buttonClass),
|
|
68
|
-
onClick: _cache[
|
|
69
|
-
role: "checkbox",
|
|
70
|
-
"aria-checked": $props.modelValue,
|
|
71
|
-
tabindex: _ctx.$attrs.disabled ? null : '0'
|
|
102
|
+
onClick: _cache[2] || (_cache[2] = $event => ($options.onClick($event)))
|
|
72
103
|
}, [
|
|
104
|
+
createElementVNode("span", _hoisted_1, [
|
|
105
|
+
createElementVNode("input", mergeProps({
|
|
106
|
+
type: "checkbox",
|
|
107
|
+
role: "switch",
|
|
108
|
+
id: $props.inputId,
|
|
109
|
+
class: $props.inputClass,
|
|
110
|
+
style: $props.inputStyle,
|
|
111
|
+
checked: $props.modelValue,
|
|
112
|
+
value: $props.modelValue,
|
|
113
|
+
"aria-labelledby": _ctx.ariaLabelledby,
|
|
114
|
+
"aria-label": _ctx.ariaLabel,
|
|
115
|
+
onFocus: _cache[0] || (_cache[0] = $event => ($options.onFocus($event))),
|
|
116
|
+
onBlur: _cache[1] || (_cache[1] = $event => ($options.onBlur($event)))
|
|
117
|
+
}, $props.inputProps), null, 16, _hoisted_2)
|
|
118
|
+
]),
|
|
73
119
|
($options.hasIcon)
|
|
74
120
|
? (openBlock(), createElementBlock("span", {
|
|
75
121
|
key: 0,
|
|
76
122
|
class: normalizeClass($options.iconClass)
|
|
77
123
|
}, null, 2))
|
|
78
124
|
: createCommentVNode("", true),
|
|
79
|
-
createElementVNode("span",
|
|
80
|
-
],
|
|
125
|
+
createElementVNode("span", _hoisted_3, toDisplayString($options.label), 1)
|
|
126
|
+
], 2)), [
|
|
81
127
|
[_directive_ripple]
|
|
82
128
|
])
|
|
83
129
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import l from"primevue/ripple";import{resolveDirective as e,withDirectives as t,openBlock as n,createElementBlock as i,normalizeClass as o,createElementVNode as a,mergeProps as s,createCommentVNode as u,toDisplayString as c}from"vue";var h={name:"ToggleButton",emits:["update:modelValue","change","click","focus","blur"],props:{modelValue:Boolean,onIcon:String,offIcon:String,onLabel:{type:String,default:"Yes"},offLabel:{type:String,default:"No"},iconPos:{type:String,default:"left"},disabled:{type:Boolean,default:!1},tabindex:{type:Number,default:null},inputId:null,inputClass:null,inputStyle:null,inputProps:null,"aria-labelledby":{type:String,default:null},"aria-label":{type:String,default:null}},methods:{onClick(l){this.disabled||(this.$emit("update:modelValue",!this.modelValue),this.$emit("change",l),this.$emit("click",l))},onFocus(l){this.$emit("focus",l)},onBlur(l){this.$emit("blur",l)}},computed:{buttonClass(){return{"p-button p-togglebutton p-component":!0,"p-button-icon-only":this.hasIcon&&!this.hasLabel,"p-disabled":this.disabled,"p-highlight":!0===this.modelValue}},iconClass(){return[this.modelValue?this.onIcon:this.offIcon,"p-button-icon",{"p-button-icon-left":"left"===this.iconPos&&this.label,"p-button-icon-right":"right"===this.iconPos&&this.label}]},hasLabel(){return this.onLabel&&this.onLabel.length>0&&this.offLabel&&this.offLabel.length>0},hasIcon(){return this.onIcon&&this.onIcon.length>0&&this.offIcon&&this.offIcon.length>0},label(){return this.hasLabel?this.modelValue?this.onLabel:this.offLabel:" "}},directives:{ripple:l}};const r={class:"p-hidden-accessible"},p=["id","checked","value","aria-labelledby","aria-label"],b={class:"p-button-label"};h.render=function(l,h,d,f,m,g){const y=e("ripple");return t((n(),i("div",{class:o(g.buttonClass),onClick:h[2]||(h[2]=l=>g.onClick(l))},[a("span",r,[a("input",s({type:"checkbox",role:"switch",id:d.inputId,class:d.inputClass,style:d.inputStyle,checked:d.modelValue,value:d.modelValue,"aria-labelledby":l.ariaLabelledby,"aria-label":l.ariaLabel,onFocus:h[0]||(h[0]=l=>g.onFocus(l)),onBlur:h[1]||(h[1]=l=>g.onBlur(l))},d.inputProps),null,16,p)]),g.hasIcon?(n(),i("span",{key:0,class:o(g.iconClass)},null,2)):u("",!0),a("span",b,c(g.label),1)],2)),[[y]])};export{h as default};
|
|
@@ -8,24 +8,57 @@ this.primevue.togglebutton = (function (Ripple, vue) {
|
|
|
8
8
|
|
|
9
9
|
var script = {
|
|
10
10
|
name: 'ToggleButton',
|
|
11
|
-
emits: ['update:modelValue', 'change'],
|
|
11
|
+
emits: ['update:modelValue', 'change', 'click', 'focus', 'blur'],
|
|
12
12
|
props: {
|
|
13
13
|
modelValue: Boolean,
|
|
14
14
|
onIcon: String,
|
|
15
15
|
offIcon: String,
|
|
16
|
-
onLabel:
|
|
17
|
-
|
|
16
|
+
onLabel: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: 'Yes'
|
|
19
|
+
},
|
|
20
|
+
offLabel: {
|
|
21
|
+
type: String,
|
|
22
|
+
default: 'No'
|
|
23
|
+
},
|
|
18
24
|
iconPos: {
|
|
19
25
|
type: String,
|
|
20
26
|
default: 'left'
|
|
27
|
+
},
|
|
28
|
+
disabled: {
|
|
29
|
+
type: Boolean,
|
|
30
|
+
default: false
|
|
31
|
+
},
|
|
32
|
+
tabindex: {
|
|
33
|
+
type: Number,
|
|
34
|
+
default: null
|
|
35
|
+
},
|
|
36
|
+
inputId: null,
|
|
37
|
+
inputClass: null,
|
|
38
|
+
inputStyle: null,
|
|
39
|
+
inputProps: null,
|
|
40
|
+
'aria-labelledby': {
|
|
41
|
+
type: String,
|
|
42
|
+
default: null
|
|
43
|
+
},
|
|
44
|
+
'aria-label': {
|
|
45
|
+
type: String,
|
|
46
|
+
default: null
|
|
21
47
|
}
|
|
22
48
|
},
|
|
23
49
|
methods: {
|
|
24
50
|
onClick(event) {
|
|
25
|
-
if (!this
|
|
51
|
+
if (!this.disabled) {
|
|
26
52
|
this.$emit('update:modelValue', !this.modelValue);
|
|
27
53
|
this.$emit('change', event);
|
|
54
|
+
this.$emit('click', event);
|
|
28
55
|
}
|
|
56
|
+
},
|
|
57
|
+
onFocus(event) {
|
|
58
|
+
this.$emit('focus', event);
|
|
59
|
+
},
|
|
60
|
+
onBlur(event) {
|
|
61
|
+
this.$emit('blur', event);
|
|
29
62
|
}
|
|
30
63
|
},
|
|
31
64
|
computed: {
|
|
@@ -33,7 +66,7 @@ this.primevue.togglebutton = (function (Ripple, vue) {
|
|
|
33
66
|
return {
|
|
34
67
|
'p-button p-togglebutton p-component': true,
|
|
35
68
|
'p-button-icon-only': this.hasIcon && !this.hasLabel,
|
|
36
|
-
'p-disabled': this
|
|
69
|
+
'p-disabled': this.disabled,
|
|
37
70
|
'p-highlight': this.modelValue === true
|
|
38
71
|
}
|
|
39
72
|
},
|
|
@@ -62,27 +95,40 @@ this.primevue.togglebutton = (function (Ripple, vue) {
|
|
|
62
95
|
}
|
|
63
96
|
};
|
|
64
97
|
|
|
65
|
-
const _hoisted_1 =
|
|
66
|
-
const _hoisted_2 =
|
|
98
|
+
const _hoisted_1 = { class: "p-hidden-accessible" };
|
|
99
|
+
const _hoisted_2 = ["id", "checked", "value", "aria-labelledby", "aria-label"];
|
|
100
|
+
const _hoisted_3 = { class: "p-button-label" };
|
|
67
101
|
|
|
68
102
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
69
103
|
const _directive_ripple = vue.resolveDirective("ripple");
|
|
70
104
|
|
|
71
105
|
return vue.withDirectives((vue.openBlock(), vue.createElementBlock("div", {
|
|
72
106
|
class: vue.normalizeClass($options.buttonClass),
|
|
73
|
-
onClick: _cache[
|
|
74
|
-
role: "checkbox",
|
|
75
|
-
"aria-checked": $props.modelValue,
|
|
76
|
-
tabindex: _ctx.$attrs.disabled ? null : '0'
|
|
107
|
+
onClick: _cache[2] || (_cache[2] = $event => ($options.onClick($event)))
|
|
77
108
|
}, [
|
|
109
|
+
vue.createElementVNode("span", _hoisted_1, [
|
|
110
|
+
vue.createElementVNode("input", vue.mergeProps({
|
|
111
|
+
type: "checkbox",
|
|
112
|
+
role: "switch",
|
|
113
|
+
id: $props.inputId,
|
|
114
|
+
class: $props.inputClass,
|
|
115
|
+
style: $props.inputStyle,
|
|
116
|
+
checked: $props.modelValue,
|
|
117
|
+
value: $props.modelValue,
|
|
118
|
+
"aria-labelledby": _ctx.ariaLabelledby,
|
|
119
|
+
"aria-label": _ctx.ariaLabel,
|
|
120
|
+
onFocus: _cache[0] || (_cache[0] = $event => ($options.onFocus($event))),
|
|
121
|
+
onBlur: _cache[1] || (_cache[1] = $event => ($options.onBlur($event)))
|
|
122
|
+
}, $props.inputProps), null, 16, _hoisted_2)
|
|
123
|
+
]),
|
|
78
124
|
($options.hasIcon)
|
|
79
125
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
80
126
|
key: 0,
|
|
81
127
|
class: vue.normalizeClass($options.iconClass)
|
|
82
128
|
}, null, 2))
|
|
83
129
|
: vue.createCommentVNode("", true),
|
|
84
|
-
vue.createElementVNode("span",
|
|
85
|
-
],
|
|
130
|
+
vue.createElementVNode("span", _hoisted_3, vue.toDisplayString($options.label), 1)
|
|
131
|
+
], 2)), [
|
|
86
132
|
[_directive_ripple]
|
|
87
133
|
])
|
|
88
134
|
}
|