vx-vue 0.7.7 → 0.8.0

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/README.md CHANGED
@@ -4,8 +4,8 @@
4
4
  VxVue provides a handful of reusable Vue components styled with Tailwind CSS. All components are geared towards simplicity leaving room for customizations, extensions or adaptations. At some point a more verbose documentation than this brief readme might emerge.
5
5
 
6
6
  ## Requirements
7
- * Vue.js 3.*
8
- * Tailwind CSS 3.*
7
+ * Vue.js 3.4+
8
+ * Tailwind CSS 3.4+
9
9
 
10
10
  The official Tailwind CSS forms plugin is used to provide basic styling of the form components using the class strategy which allows the styling of non-form elements consistently.
11
11
  An easy to configure color theming is applied. `vxvue` and `vxvue-alt` are used as the two colors scales. Since Tailwind won't observe classes in imported components tailwind.config.js should also list the node package in the content array.
@@ -45,20 +45,125 @@ The components use an extra color palette.
45
45
  ## Provided components
46
46
  So far the following components have been implemented:
47
47
 
48
- | element | description | props | events | slots |
49
- |--------------------|------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------|--------------------------------------------------|
50
- | `autocomplete` | component which provides suggestions with each keystroke | `modelValue [String]`<br/>`search [Function]`<br/>`baseClass [String]`<br/>`resultListClass [String]`<br/>`resultItemClass [String]`<br/>`inputClass [String]`<br/>`autoSelect [Boolean]`<br/>`getResultValue [Function]` | `update:modelValue`<br/>`blur`<br/>`submit` | `result` |
51
- | `confirm` | promise-based component which can either take one ("confirm") or two buttons ("confirm", "cancel") | | | `title`<br/>`icon`<br/>`message` |
52
- | `date-input` | input element for guided date inputs, also used by the datepicker | `modelValue [Date]`<br/>`outputFormat [String]`<br/>`inputFormat [String]`<br/>`showButton [Boolean]`<br/>`locale [String]` | `update:modelValue`<br/>`toggle-datepicker` | `default` |
53
- | `datepicker` | a bare bones datepicker component | `modelValue [Date]`<br/>`validFrom [Date]`<br/>`validUntil [Date]`<br/>`dayNames [Array]`<br/>`locale [String]`<br/>`startOfWeekIndex [Number]`<br/>`hasInput [Boolean]` | `update:modelValue`<br/>`month-change`<br/>`year-change` | `default` |
54
- | `form-file-button` | a thinly wrapped type-file input to allow proper styling and integration | `modelValue [Array]`<br/>`accept [String]`<br/>`multiple [Boolean]`<br/>`name [String]`<br/>`id [String]` | `update:modelValue`<br/>`form-data` | |
55
- | `form-select` | a select element adapted for Vue.js integration | `modelValue [String, Number]`<br/>`options [Array]`<br/>`disabledLabel [String]` | `update:modelValue` | |
56
- | `form-switch` | a fancy checkbox | `modelValue [Mixed]` | `update:modelValue` | `default` |
57
- | `message-toast` | displays a notification which dismisses itself after a configurable timeout | `title [String]`<br/>`message [String, Array]`<br/>`timeout [Number]`<br/>`active [Boolean]` | `timeout`<br/>`close` | `icon`<br/>`title`<br/>`default` |
58
- | `modal` | modal overlay | `show [Boolean]`<br/>`containerClass [String]`<br/>`headerClass [String]`<br/>`contentClass [String]` | `clicked-outside` | `title`<br/>`default` |
59
- | `pagination` | a pagination component for arbitrary items; opinionated in its layout | `page [Number]`<br/>`total [Number]`<br/>`perPage [Number]`<br/>`showNavButtons [Boolean]`<br/>`prevText [String]`<br/>`nextText [String]`<br/>`showAllPages [Boolean]`<br/>`markerPosition ['above', 'below']` | `update:page` | |
60
- | `password-input` | a simple input with toggle button which toggles between `type='button'` and `type='text'` | `modelValue [String]` | `update:modelValue` | `default` |
61
- | `simple-tree` | a simple tree implemented with a recursive component | `branch [Object]` | `branch-selected`<br/>`expand` | |
62
- | `slider` | a slider with one or more thumbs; `modelValue` can be a number or an array of numbers; the length of the array determines the number of thumbs | `modelValue [Number]`<br/>`min [Number]`<br/>`max [Number]`<br/>`vertical [Boolean]`<br/>`disabled [Boolean]` | `update:modelValue` | |
63
- | `sortable` | a sortable table; the `columns` prop specifies the columns and their sorting options | `columns [Array]`<br/>`rows [Array]`<br/>`offset [Number]`<br/>`count [Number]`<br/>`sortProp [String]`<br/>`sortDirection ['asc', 'desc']`<br/>`keyProperty [String]` | `before-sort`<br/>`after-sort` | `{ column: prop }-header`<br/>`{ column: prop }` |
64
- | `tabs` | a tabs component which allows both badges and icons | `items [Array]`<br/>`activeIndex [Number]` | `update:active-index` | `icon`<br/>`default` |
48
+ ### Accordion
49
+ An Accordion; requires AccordionPanels as child components. Key navigation with tab, cursor up, cursor down is provided.
50
+ If `activeIndex` is an array multiple panels can be open at the same time; if it is a number only one panel at a time can be open.
51
+
52
+ | props | events | slots |
53
+ |-------------------------------|------------------------|-------|
54
+ | `activeIndex [Number, Array]` | `update:active-index` | |
55
+
56
+ ### AccordionPanel
57
+ **Only** useful as child component of an Accordion component.
58
+
59
+ | props | events | slots |
60
+ |----------------------------------------|----------------------------------|-----------------------|
61
+ | `show [Boolean]<br>`disabled [Boolean] | `keyup`<br>`keydown`<br>`select` | `header`<br>`default` |
62
+
63
+
64
+ ### Autocomplete
65
+ A component which provides suggestions with each keystroke.
66
+
67
+ | props | events | slots |
68
+ |----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------|-----------|
69
+ | `modelValue [String]`<br/>`search [Function]`<br/>`baseClass [String]`<br/>`resultListClass [String]`<br/>`resultItemClass [String]`<br/>`inputClass [String]`<br/>`autoSelect [Boolean]`<br/>`getResultValue [Function]` | `update:modelValue`<br/>`blur`<br/>`submit` | `result` |
70
+
71
+ ### Confirm
72
+ A promise-based component which can either take one ("confirm") or two buttons ("confirm", "cancel"). Clicking "confirm" resolves, "cancel" rejects the promise.
73
+
74
+ | props | events | slots |
75
+ |-------|--------|----------------------------------|
76
+ | none | none | `title`<br/>`icon`<br/>`message` |
77
+
78
+ ### DateInput
79
+ An input element for guided date inputs, which also serves as child component of the datepicker component.
80
+
81
+ | props | events | slots |
82
+ |-----------------------------------------------------------------------------------------------------------------------------|---------------------------------------------|-----------|
83
+ | `modelValue [Date]`<br/>`outputFormat [String]`<br/>`inputFormat [String]`<br/>`showButton [Boolean]`<br/>`locale [String]` | `update:modelValue`<br/>`toggle-datepicker` | `default` |
84
+
85
+ ### Datepicker
86
+ A not-too-fancy datepicker.
87
+
88
+ | props | events | slots |
89
+ |--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------|-----------|
90
+ | `modelValue [Date]`<br/>`validFrom [Date]`<br/>`validUntil [Date]`<br/>`dayNames [Array]`<br/>`locale [String]`<br/>`startOfWeekIndex [Number]`<br/>`hasInput [Boolean]` | `update:modelValue`<br/>`month-change`<br/>`year-change` | `default` |
91
+
92
+ ### FormFileButton
93
+ A thinly wrapped type-file input that allows proper styling and integration.
94
+
95
+ | props | events | slots |
96
+ |-----------------------------------------------------------------------------------------------------------|-------------------------------------|-------|
97
+ | `modelValue [Array]`<br/>`accept [String]`<br/>`multiple [Boolean]`<br/>`name [String]`<br/>`id [String]` | `update:modelValue`<br/>`form-data` | none |
98
+
99
+ ### FormSelect
100
+ A select element adapted for Vue.js integration.
101
+
102
+ | props | events | slots |
103
+ |----------------------------------------------------------------------------------|---------------------|-------|
104
+ | `modelValue [String, Number]`<br/>`options [Array]`<br/>`disabledLabel [String]` | `update:modelValue` | none |
105
+
106
+ ### FormSwitch
107
+ Nothing more than a fancy checkbox.
108
+
109
+ | props | events | slots |
110
+ |----------------------|---------------------|-----------|
111
+ | `modelValue [Mixed]` | `update:modelValue` | `default` |
112
+
113
+ ### MessageToast
114
+ Displays a notification message which can either be dismissed by the user and/or by itself after a configurable timeout.
115
+
116
+ | props | events | slots |
117
+ |----------------------------------------------------------------------------------------------|-----------------------|----------------------------------|
118
+ | `title [String]`<br/>`message [String, Array]`<br/>`timeout [Number]`<br/>`active [Boolean]` | `timeout`<br/>`close` | `icon`<br/>`title`<br/>`default` |
119
+
120
+ ### Modal
121
+ A modal overlay which provides slots.
122
+
123
+ | props | events | slots |
124
+ |-------------------------------------------------------------------------------------------------------|-------------------|-----------------------|
125
+ | `show [Boolean]`<br/>`containerClass [String]`<br/>`headerClass [String]`<br/>`contentClass [String]` | `clicked-outside` | `title`<br/>`default` |
126
+
127
+ ### Pagination
128
+ A pagination component for an arbitrary list of items; rather opinionated in its responsive layout.
129
+
130
+ | props | events | slots |
131
+ |-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------|-------|
132
+ | `page [Number]`<br/>`total [Number]`<br/>`perPage [Number]`<br/>`showNavButtons [Boolean]`<br/>`prevText [String]`<br/>`nextText [String]`<br/>`showAllPages [Boolean]`<br/>`markerPosition ['above', 'below']` | `update:page` | none |
133
+
134
+ ### PasswordInput
135
+ A simple input element paired with a toggle button which toggles the input element between between `type='password'` and `type='text'`
136
+
137
+ | props | events | slots |
138
+ |-----------------------|---------------------|-----------|
139
+ | `modelValue [String]` | `update:modelValue` | `default` |
140
+
141
+ ### SimpleTree
142
+ A collapsible tree component which is implemented by a single recursive component.
143
+
144
+ | props | events | slots |
145
+ |-------------------|--------------------------------|-------|
146
+ | `branch [Object]` | `branch-selected`<br/>`expand` | none |
147
+
148
+ ### Slider
149
+ A slider replacing and enhancing an `input type="range"`.
150
+
151
+ The component can have one or more thumbs: `modelValue` can either be a number or an array of numbers and the length of the array determines the number of thumbs.
152
+
153
+ | props | events | slots |
154
+ |---------------------------------------------------------------------------------------------------------------|---------------------|-------|
155
+ | `modelValue [Number]`<br/>`min [Number]`<br/>`max [Number]`<br/>`vertical [Boolean]`<br/>`disabled [Boolean]` | `update:modelValue` | none |
156
+
157
+ ### Sortable
158
+ A sortable table; the `columns` prop specifies the columns and their sorting options.
159
+
160
+ | props | events | slots |
161
+ |------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------|--------------------------------------------------|
162
+ | `columns [Array]`<br/>`rows [Array]`<br/>`offset [Number]`<br/>`count [Number]`<br/>`sortProp [String]`<br/>`sortDirection ['asc', 'desc']`<br/>`keyProperty [String]` | `before-sort`<br/>`after-sort` | `{ column: prop }-header`<br/>`{ column: prop }` |
163
+
164
+ ### Tabs
165
+ A responsive tabs component. The items array holds objects with a required `name [String]` and optional `badge [String]`, `icon [Component]` and `disabled [Boolean]` properties.
166
+
167
+ | props | events | slots |
168
+ |--------------------------------------------|-----------------------|----------------------|
169
+ | `items [Array]`<br/>`activeIndex [Number]` | `update:active-index` | `icon`<br/>`default` |
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .messagetoast-fade-enter-from[data-v-62f8007a],.messagetoast-fade-leave-to[data-v-62f8007a]{--tw-translate-y: -2.5rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate3d(var(--tw-translate-x),var(--tw-translate-y),0) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:0}.messagetoast-fade-enter-to[data-v-62f8007a],.messagetoast-fade-leave-from[data-v-62f8007a]{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:1}.messagetoast-fade-enter-active[data-v-62f8007a],.messagetoast-fade-leave-active[data-v-62f8007a]{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}tbody tr[data-v-f823032d]:nth-of-type(odd){--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity))}tbody tr[data-v-f823032d]:nth-of-type(2n){--tw-bg-opacity: 1;background-color:rgb(226 232 240 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity))}tbody tr:nth-of-type(odd) td.active[data-v-f823032d]{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity))}tbody tr:nth-of-type(2n) td.active[data-v-f823032d]{--tw-bg-opacity: 1;background-color:rgb(253 230 138 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(146 64 14 / var(--tw-text-opacity))}thead th.active[data-v-f823032d]{--tw-bg-opacity: 1;background-color:rgb(146 64 14 / var(--tw-bg-opacity))}
1
+ .messagetoast-fade-enter-from[data-v-62f8007a],.messagetoast-fade-leave-to[data-v-62f8007a]{--tw-translate-y: -2.5rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate3d(var(--tw-translate-x),var(--tw-translate-y),0) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:0}.messagetoast-fade-enter-to[data-v-62f8007a],.messagetoast-fade-leave-from[data-v-62f8007a]{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:1}.messagetoast-fade-enter-active[data-v-62f8007a],.messagetoast-fade-leave-active[data-v-62f8007a]{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}tbody tr[data-v-7ec18969]:nth-of-type(odd){--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity))}tbody tr[data-v-7ec18969]:nth-of-type(2n){--tw-bg-opacity: 1;background-color:rgb(226 232 240 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity))}tbody tr:nth-of-type(odd) td.active[data-v-7ec18969]{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity))}tbody tr:nth-of-type(2n) td.active[data-v-7ec18969]{--tw-bg-opacity: 1;background-color:rgb(253 230 138 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(146 64 14 / var(--tw-text-opacity))}thead th.active[data-v-7ec18969]{--tw-bg-opacity: 1;background-color:rgb(146 64 14 / var(--tw-bg-opacity))}