@ziyarago/ui 0.15.1 → 0.15.3
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/CHANGELOG.md +12 -0
- package/dist/llms-full.txt +3 -2
- package/dist/llms.txt +1 -1
- package/dist/manifest.json +7 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/core/components.js +1 -1
- package/src/meta/navigation.js +2 -1
- package/src/styles/components.css +1 -1
- package/src/vue/index.js +4 -2
- package/types/react.d.ts +6 -1
- package/types/vue.d.ts +6 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
## [0.15.3](https://github.com/ziyarago/ui/compare/v0.15.2...v0.15.3) (2026-10-21)
|
|
2
|
+
|
|
3
|
+
### Bug Fixes
|
|
4
|
+
|
|
5
|
+
* Vue adapter keeps kebab-case :model-value and still calls an explicit :on-change ([3fbfce4](https://github.com/ziyarago/ui/commit/3fbfce4a12d46d8557044c57cf60294b3ccf2aa7))
|
|
6
|
+
|
|
7
|
+
## [0.15.2](https://github.com/ziyarago/ui/compare/v0.15.1...v0.15.2) (2026-10-21)
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* SideNav scrolls instead of squeezing items, collapsible prop ([1f1190e](https://github.com/ziyarago/ui/commit/1f1190e3d5b1c79cd6b0d82b3c2e0b8970fdcd1f))
|
|
12
|
+
|
|
1
13
|
## [0.15.1](https://github.com/ziyarago/ui/compare/v0.15.0...v0.15.1) (2026-10-21)
|
|
2
14
|
|
|
3
15
|
### Bug Fixes
|
package/dist/llms-full.txt
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> ZiyaraGo UI — glass design system for Umrah and Hajj products. OKLCH tokens, two palettes, dark and light, RTL, Thmanyah. One framework-neutral core with Vue 3, Nuxt and React adapters, 102 free components and 6 page templates (more in @ziyarago/ui-pro).
|
|
4
4
|
|
|
5
|
-
Version 0.15.
|
|
5
|
+
Version 0.15.3. Docs: https://ziyara.vip . Manifest (machine readable): https://ziyara.vip/manifest.json
|
|
6
6
|
|
|
7
7
|
## Setup
|
|
8
8
|
- import { UiButton } from '@ziyarago/ui/vue'
|
|
@@ -1730,13 +1730,14 @@ Props:
|
|
|
1730
1730
|
- `items`: ({ value: string; label: string; icon?: string; count?: string | number } | { group: string })[] = "[]". Entries. An object with group renders a section heading (hidden when collapsed); others are links with an optional icon and count.
|
|
1731
1731
|
- `value`: string. Value of the active item (aria-current="page").
|
|
1732
1732
|
- `collapsed`: boolean = false. Icon-only mode; labels move to the title tooltip.
|
|
1733
|
+
- `collapsible`: boolean = false. Always draw the collapse button, even without a toggle handler (the button is also drawn when a toggle handler is set).
|
|
1733
1734
|
- `collapseLabel`: string = "Collapse". Label of the collapse button.
|
|
1734
1735
|
- `size`: 'xs' | 'sm' | 'md' | 'lg' | 'xl' = "md". Scale of width (216 to 336 px), padding and item height.
|
|
1735
1736
|
Slots:
|
|
1736
1737
|
- footer: Bottom area above the collapse button, e.g. user card. React also accepts a footer prop.
|
|
1737
1738
|
Events:
|
|
1738
1739
|
- change: Called with the value of the clicked item.
|
|
1739
|
-
- toggle: Called when the collapse button is clicked. The button is
|
|
1740
|
+
- toggle: Called when the collapse button is clicked. The button is drawn when this handler is set (Vue: @toggle) or when collapsible is true.
|
|
1740
1741
|
Notes:
|
|
1741
1742
|
- Collapsing is controlled: flip collapsed in the toggle handler.
|
|
1742
1743
|
- Group entries are keyed by their title, so keep group names unique.
|
package/dist/llms.txt
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> ZiyaraGo UI — glass design system for Umrah and Hajj products. OKLCH tokens, two palettes, dark and light, RTL, Thmanyah. One framework-neutral core with Vue 3, Nuxt and React adapters, 102 free components and 6 page templates (more in @ziyarago/ui-pro).
|
|
4
4
|
|
|
5
|
-
Version 0.15.
|
|
5
|
+
Version 0.15.3. Docs: https://ziyara.vip . Manifest (machine readable): https://ziyara.vip/manifest.json
|
|
6
6
|
|
|
7
7
|
## Setup
|
|
8
8
|
- import { UiButton } from '@ziyarago/ui/vue'
|
package/dist/manifest.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ziyarago/ui",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.3",
|
|
4
4
|
"homepage": "https://ziyara.vip",
|
|
5
5
|
"imports": {
|
|
6
6
|
"vue": "import { UiButton } from '@ziyarago/ui/vue'",
|
|
@@ -11789,6 +11789,11 @@
|
|
|
11789
11789
|
"default": false,
|
|
11790
11790
|
"description": "Icon-only mode; labels move to the title tooltip."
|
|
11791
11791
|
},
|
|
11792
|
+
"collapsible": {
|
|
11793
|
+
"type": "boolean",
|
|
11794
|
+
"default": false,
|
|
11795
|
+
"description": "Always draw the collapse button, even without a toggle handler (the button is also drawn when a toggle handler is set)."
|
|
11796
|
+
},
|
|
11792
11797
|
"collapseLabel": {
|
|
11793
11798
|
"type": "string",
|
|
11794
11799
|
"default": "Collapse",
|
|
@@ -11812,7 +11817,7 @@
|
|
|
11812
11817
|
},
|
|
11813
11818
|
"events": {
|
|
11814
11819
|
"change": "Called with the value of the clicked item.",
|
|
11815
|
-
"toggle": "Called when the collapse button is clicked. The button is
|
|
11820
|
+
"toggle": "Called when the collapse button is clicked. The button is drawn when this handler is set (Vue: @toggle) or when collapsible is true."
|
|
11816
11821
|
},
|
|
11817
11822
|
"notes": [
|
|
11818
11823
|
"Collapsing is controlled: flip collapsed in the toggle handler.",
|
package/dist/style.css
CHANGED
|
@@ -222,7 +222,7 @@
|
|
|
222
222
|
.zg-sidenav{--w:272px;position:sticky;top:0;height:100vh;width:var(--w);flex:none;display:flex;flex-direction:column;gap:6px;padding:16px 12px;background:color-mix(in oklch,var(--zg-bg) 62%,transparent);-webkit-backdrop-filter:blur(40px) saturate(1.6);backdrop-filter:blur(40px) saturate(1.6);box-shadow:inset -1px 0 0 var(--zg-stroke);transition:width .3s var(--zg-ease);overflow:hidden}
|
|
223
223
|
[dir="rtl"] .zg-sidenav{box-shadow:inset 1px 0 0 var(--zg-stroke)}
|
|
224
224
|
.zg-sidenav--collapsed{--w:76px}
|
|
225
|
-
.zg-sidenav .zg-navitem{width:100%;height:46px;border-radius:16px;justify-content:flex-start;padding:0 14px}
|
|
225
|
+
.zg-sidenav{overflow-y:auto;overscroll-behavior:contain}.zg-sidenav>*{flex-shrink:0}.zg-sidenav .zg-navitem{flex-shrink:0;width:100%;height:46px;border-radius:16px;justify-content:flex-start;padding:0 14px}
|
|
226
226
|
.zg-sidenav--collapsed .zg-navitem{justify-content:center;padding:0}.zg-sidenav--collapsed .zg-navitem span:not(.zg-icon){display:none}
|
|
227
227
|
.zg-sidenav__brand{display:flex;align-items:center;gap:10px;padding:6px 8px 14px;font:700 18px var(--zg-font);white-space:nowrap}
|
|
228
228
|
.zg-sidenav--collapsed .zg-sidenav__brand span{display:none}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ziyarago/ui",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.3",
|
|
4
4
|
"description": "ZiyaraGo UI — glass design system for Umrah and Hajj products. OKLCH tokens, two palettes, dark and light, RTL, Thmanyah. One framework-neutral core with Vue 3, Nuxt and React adapters, 102 free components and 6 page templates (more in @ziyarago/ui-pro).",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ui",
|
package/src/core/components.js
CHANGED
|
@@ -118,7 +118,7 @@ export const components = {
|
|
|
118
118
|
Timeline: { render: ({ h, props: p }) => h('div', { class: 'zg-timeline' }, ...(p.items || []).map((it, i, a) => h('div', { key: i, class: 'zg-tl' }, h('div', { class: 'zg-tl__rail' }, h('span', { class: 'zg-tl__dot' }), i < a.length - 1 ? h('span', { class: 'zg-tl__line' }) : null), h('div', { class: 'zg-tl__body' }, h('b', null, it.title), it.text ? h('span', null, it.text) : null, h('span', { class: 'zg-tl__time' }, it.time))))) },
|
|
119
119
|
TopNav: { render: ({ h, props: p, slots }) => h('header', { class: 'zg-topnav' }, h('div', { class: 'zg-topnav__brand' }, p.brand), h('nav', { class: 'zg-topnav__items', 'aria-label': t('TopNav', 'label') }, ...(p.items || []).map(it => nav(h, it, p.value, p.onChange))), h('div', { class: 'zg-topnav__actions' }, slots.actions || p.actions || null)) },
|
|
120
120
|
SideNav: { render: ({ h, props: p, slots }) => h('aside', { class: cx('zg-sidenav', p.collapsed && 'zg-sidenav--collapsed') }, h('div', { class: 'zg-sidenav__brand' }, p.brand), ...(p.items || []).map(it => it.group ? h('div', { key: it.group, class: 'zg-sidenav__group', style: p.collapsed ? { display: 'none' } : undefined }, it.group) : nav(h, it, p.value, p.onChange, p.collapsed)), h('div', { class: 'zg-sidenav__sp' }), slots.footer || p.footer || null,
|
|
121
|
-
p.onToggle ? h('button', { type: 'button', class: 'zg-navitem', onClick: p.onToggle, 'aria-label': t('SideNav', 'toggle') }, icon(h, p.collapsed ? 'panel-left-open' : 'panel-left-close', 18), h('span', null, p.collapseLabel || t('SideNav', 'collapse'))) : null) },
|
|
121
|
+
(p.onToggle || p.collapsible) ? h('button', { type: 'button', class: 'zg-navitem', onClick: p.onToggle, 'aria-label': t('SideNav', 'toggle') }, icon(h, p.collapsed ? 'panel-left-open' : 'panel-left-close', 18), h('span', null, p.collapseLabel || t('SideNav', 'collapse'))) : null) },
|
|
122
122
|
AppShell: { state: { collapsed: false }, render: ({ C, h, props: p, children, slots, state, set }) => {
|
|
123
123
|
const brand = p.brand, top = (p.nav || 'top') === 'top', col = p.collapsed ?? state.collapsed, toggle = () => p.onCollapse ? p.onCollapse(!col) : set({ collapsed: !state.collapsed });
|
|
124
124
|
return h('div', { class: cx('zg-root', 'zg-shell', top && 'zg-shell--top', p.frame && 'zg-shell--frame'), style: { background: 'var(--zg-bg)' } },
|
package/src/meta/navigation.js
CHANGED
|
@@ -25,11 +25,12 @@ export default {
|
|
|
25
25
|
items: { type: '({ value: string; label: string; icon?: string; count?: string | number } | { group: string })[]', default: '[]', description: 'Entries. An object with group renders a section heading (hidden when collapsed); others are links with an optional icon and count.' },
|
|
26
26
|
value: current,
|
|
27
27
|
collapsed: { type: 'boolean', default: false, description: 'Icon-only mode; labels move to the title tooltip.' },
|
|
28
|
+
collapsible: { type: 'boolean', default: false, description: 'Always draw the collapse button, even without a toggle handler (the button is also drawn when a toggle handler is set).' },
|
|
28
29
|
collapseLabel: { type: 'string', default: 'Collapse', description: 'Label of the collapse button.' },
|
|
29
30
|
size: size('width (216 to 336 px), padding and item height'),
|
|
30
31
|
},
|
|
31
32
|
slots: { footer: 'Bottom area above the collapse button, e.g. user card. React also accepts a footer prop.' },
|
|
32
|
-
events: { change: 'Called with the value of the clicked item.', toggle: 'Called when the collapse button is clicked. The button is
|
|
33
|
+
events: { change: 'Called with the value of the clicked item.', toggle: 'Called when the collapse button is clicked. The button is drawn when this handler is set (Vue: @toggle) or when collapsible is true.' },
|
|
33
34
|
notes: ['Collapsing is controlled: flip collapsed in the toggle handler.', 'Group entries are keyed by their title, so keep group names unique.'],
|
|
34
35
|
},
|
|
35
36
|
|
|
@@ -140,7 +140,7 @@
|
|
|
140
140
|
.zg-sidenav{--w:272px;position:sticky;top:0;height:100vh;width:var(--w);flex:none;display:flex;flex-direction:column;gap:6px;padding:16px 12px;background:color-mix(in oklch,var(--zg-bg) 62%,transparent);-webkit-backdrop-filter:blur(40px) saturate(1.6);backdrop-filter:blur(40px) saturate(1.6);box-shadow:inset -1px 0 0 var(--zg-stroke);transition:width .3s var(--zg-ease);overflow:hidden}
|
|
141
141
|
[dir="rtl"] .zg-sidenav{box-shadow:inset 1px 0 0 var(--zg-stroke)}
|
|
142
142
|
.zg-sidenav--collapsed{--w:76px}
|
|
143
|
-
.zg-sidenav .zg-navitem{width:100%;height:46px;border-radius:16px;justify-content:flex-start;padding:0 14px}
|
|
143
|
+
.zg-sidenav{overflow-y:auto;overscroll-behavior:contain}.zg-sidenav>*{flex-shrink:0}.zg-sidenav .zg-navitem{flex-shrink:0;width:100%;height:46px;border-radius:16px;justify-content:flex-start;padding:0 14px}
|
|
144
144
|
.zg-sidenav--collapsed .zg-navitem{justify-content:center;padding:0}.zg-sidenav--collapsed .zg-navitem span:not(.zg-icon){display:none}
|
|
145
145
|
.zg-sidenav__brand{display:flex;align-items:center;gap:10px;padding:6px 8px 14px;font:700 18px var(--zg-font);white-space:nowrap}
|
|
146
146
|
.zg-sidenav--collapsed .zg-sidenav__brand span{display:none}
|
package/src/vue/index.js
CHANGED
|
@@ -16,8 +16,10 @@ const wrap = (name, def) => defineComponent({
|
|
|
16
16
|
void localeTick.value;
|
|
17
17
|
const props = {}, root = {};
|
|
18
18
|
for (const k in attrs) { if (/^(aria|data)-|^(class|style|id)$/.test(k)) root[k] = attrs[k]; const pk = k.includes('-') && !/^(aria|data)-/.test(k) ? k.replace(/-([a-z])/g, (_, c) => c.toUpperCase()) : k; props[pk] = attrs[k] === '' && BOOL_PROPS.has(pk) ? true : attrs[k]; }
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
// an explicit :on-change handler (kebab-case attribute) is still called after the v-model and @change emitters
|
|
20
|
+
const userChange = typeof props.onChange === 'function' ? props.onChange : null;
|
|
21
|
+
props.onChange = v => { emit('update:modelValue', v); emit('change', v); if (userChange) userChange(v); };
|
|
22
|
+
if (props.modelValue === undefined) delete props.modelValue;
|
|
21
23
|
const named = {}; for (const k of Object.keys(slots)) if (k !== 'default') named[k] = slots[k]();
|
|
22
24
|
const children = slots.default ? slots.default() : [];
|
|
23
25
|
const out = def.render({ C, h: vh, props, children, slots: named, state, set, portal: (kids, to) => mounted.value ? h(Teleport, { to: to || 'body' }, kids) : null });
|
package/types/react.d.ts
CHANGED
|
@@ -2821,6 +2821,11 @@ export interface UiSideNavProps {
|
|
|
2821
2821
|
* @default false
|
|
2822
2822
|
*/
|
|
2823
2823
|
collapsed?: boolean;
|
|
2824
|
+
/**
|
|
2825
|
+
* Always draw the collapse button, even without a toggle handler (the button is also drawn when a toggle handler is set).
|
|
2826
|
+
* @default false
|
|
2827
|
+
*/
|
|
2828
|
+
collapsible?: boolean;
|
|
2824
2829
|
/**
|
|
2825
2830
|
* Label of the collapse button.
|
|
2826
2831
|
* @default 'Collapse'
|
|
@@ -2837,7 +2842,7 @@ export interface UiSideNavProps {
|
|
|
2837
2842
|
*/
|
|
2838
2843
|
onChange?: (value: string) => void;
|
|
2839
2844
|
/**
|
|
2840
|
-
* Called when the collapse button is clicked. The button is
|
|
2845
|
+
* Called when the collapse button is clicked. The button is drawn when this handler is set (Vue: @toggle) or when collapsible is true.
|
|
2841
2846
|
* @event toggle
|
|
2842
2847
|
*/
|
|
2843
2848
|
onToggle?: () => void;
|
package/types/vue.d.ts
CHANGED
|
@@ -2828,6 +2828,11 @@ export interface UiSideNavProps {
|
|
|
2828
2828
|
* @default false
|
|
2829
2829
|
*/
|
|
2830
2830
|
collapsed?: boolean;
|
|
2831
|
+
/**
|
|
2832
|
+
* Always draw the collapse button, even without a toggle handler (the button is also drawn when a toggle handler is set).
|
|
2833
|
+
* @default false
|
|
2834
|
+
*/
|
|
2835
|
+
collapsible?: boolean;
|
|
2831
2836
|
/**
|
|
2832
2837
|
* Label of the collapse button.
|
|
2833
2838
|
* @default 'Collapse'
|
|
@@ -2844,7 +2849,7 @@ export interface UiSideNavProps {
|
|
|
2844
2849
|
*/
|
|
2845
2850
|
onChange?: (value: string) => void;
|
|
2846
2851
|
/**
|
|
2847
|
-
* Called when the collapse button is clicked. The button is
|
|
2852
|
+
* Called when the collapse button is clicked. The button is drawn when this handler is set (Vue: @toggle) or when collapsible is true.
|
|
2848
2853
|
* @event toggle
|
|
2849
2854
|
*/
|
|
2850
2855
|
onToggle?: () => void;
|