@gjsify/adwaita-nativescript 0.49.0 → 0.50.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/lib/esm/index.js CHANGED
@@ -1 +1 @@
1
- import"./_virtual/_rolldown/runtime.js";import{ADWAITA_SANS_FONT_FAMILY as ee,ADWAITA_SANS_TTF_FILES as te,adwaitaFontInstallInstructions as ne,hasAdwaitaSans as e}from"./fonts.js";import{GTK_ALIGN as t}from"./widgets/gtk-align.js";import{applyConstructProps as n,nsAlignment as r}from"./widgets/construct-props.js";import{ACTIVATED as i}from"./widgets/adw-action-row.js";import{NOTIFY_ACTIVE as a}from"./widgets/adw-switch-row.js";import{adwaitaColorScheme as o,isThemeIconColor as s,onAdwaitaColorSchemeChanged as c,setAdwaitaColorScheme as l,themeIconColor as u,toggleAdwaitaColorScheme as d}from"./widgets/color-scheme.js";import{ADWAITA_ICON_GRID as f,DEFAULT_ICON_COLOR as p,DEFAULT_ICON_COLOR_DARK as m,extractIconPaths as h,extractPathData as g}from"./widgets/icon-path.js";import{ICON_FALLBACK_NAME as _,compiledIconNames as v,iconValueKind as y,isIconAvailable as b,registerIcon as x,registeredIconNames as S,resolveIconSource as C,unregisterIcon as w}from"./widgets/icon-theme.js";import{renderSymbolicIcon as T}from"./widgets/icons.js";import{DEFAULT_GTK_IMAGE_SIZE as E}from"./widgets/gtk-image.js";import{attachRowPressFeedback as D}from"./widgets/row-press.js";import{AdwImageButton as O,DEFAULT_ICON_BUTTON_ICON_SIZE as k}from"./widgets/adw-image-button.js";import{NOTIFY_TEXT as A}from"./widgets/adw-entry-row.js";import{ACTIVATE as j,NOTIFY_TEXT as M}from"./widgets/gtk-entry.js";import{ComboState as N,NOTIFY_SELECTED as P}from"./widgets/adw-combo-row.js";import{NOTIFY_SELECTED as F}from"./widgets/gtk-drop-down.js";import{NOTIFY_VALUE as I,SpinState as L}from"./widgets/adw-spin-row.js";import{AdwSliderRow as R,NOTIFY_SLIDER_VALUE as z}from"./widgets/adw-slider-row.js";import{ExpanderState as B,NOTIFY_EXPANDED as V}from"./widgets/adw-expander-row.js";import{buttonSlotAfterWrite as H,buttonSlotDetaches as U}from"./widgets/button-slot.js";import{labelDisplayText as W,labelMarkupIsUnparseable as G}from"./widgets/label-text.js";import{GTK_BUTTON_CLICKED as K,GTK_BUTTON_LABEL_CLASS as q}from"./widgets/gtk-button.js";import{DEFAULT_BOX_SPACING as J,boxChildMargin as Y,boxSpacingChanges as X,normalizeBoxSpacing as Z}from"./widgets/box-layout.js";import{MENU_ITEM_ACTIVATED as re}from"./widgets/gtk-menu-button.js";import{DEFAULT_CLAMP_MAX_SIZE as ie,DEFAULT_SPINNER_SIZE as ae}from"./widgets/chrome.js";import{BUTTON_CLICKED as oe}from"./widgets/adw-banner.js";import{avatarInitials as se}from"./widgets/avatar-color.js";import{AVATAR_DEFAULT_ICON as ce}from"./widgets/avatar-view.js";import{DEFAULT_AVATAR_SIZE as le}from"./widgets/adw-avatar.js";import{DATA_GRID_HEADER_CELL_CLASS as ue,DATA_GRID_HEADER_ROW_CLASS as de,DATA_GRID_SECTION_CELL_CLASS as Q,dataGridCellClass as fe,dataGridItemSpec as pe,dataGridRowClass as me,dataGridShapeKey as he,dataGridTracksKey as ge,parseDataGridWidth as _e}from"./widgets/data-grid-model.js";import{AdwDataGrid as ve,ROW_ACTIVATED as ye}from"./widgets/adw-data-grid.js";import{CLICKED as be,MENU_TAPPED as xe}from"./widgets/adw-split-button.js";import{NOTIFY_SELECTED as Se,ToggleGroupState as Ce}from"./widgets/adw-toggle-group.js";import{ADWAITA_NS_ACCENT_RULES as we,adwaitaNsAccentColor as Te,adwaitaNsAccentCss as Ee}from"./widgets/accent-theme.js";import{applyAdwaitaNsAccent as De,clearAdwaitaNsAccent as Oe}from"./widgets/adw-accent.js";import{SHORTCUT_LABEL_CAP_TEXT_CLASS as ke,SHORTCUT_LABEL_CLASS as Ae,SHORTCUT_LABEL_DIMMED_CLASS as je,SHORTCUT_LABEL_DISABLED_CLASS as Me,SHORTCUT_LABEL_KEYCAP_CLASS as Ne,SHORTCUT_LABEL_KEYS_CLASS as Pe,SHORTCUT_LABEL_SIDE_CLASS as Fe,SHORTCUT_LABEL_SPACED_CLASS as Ie,shortcutLabelDirection as Le,shortcutLabelPlatform as Re,shortcutLabelRenderPlan as ze}from"./widgets/shortcut-label.js";import{NOTIFY_VISIBLE_CHILD as Be}from"./widgets/adw-view-stack.js";import{AdwViewSwitcherBase as Ve,NOTIFY_SELECTED as He}from"./widgets/view-switcher-base.js";import{DEFAULT_CAROUSEL_PAGE_WIDTH as Ue}from"./widgets/carousel-state.js";import{NOTIFY_POSITION as We}from"./widgets/adw-carousel.js";import{NOTIFY_VISIBLE_PAGE as Ge}from"./widgets/navigation-stack.js";import{NsNavigationSplitViewState as Ke,NsOverlaySplitViewState as qe,splitViewColumns as Je}from"./widgets/split-view-state.js";import{AdwSplitViewBase as Ye,NOTIFY_SHOW_SIDEBAR as Xe}from"./widgets/split-view-base.js";import{NOTIFY_SELECTED as Ze}from"./widgets/adw-sidebar.js";import{NOTIFY_OPEN as Qe}from"./widgets/bottom-sheet-state.js";import{AdwToast as $e,AdwToastQueue as et,DEFAULT_TOAST_TIMEOUT as tt,TOAST_BUTTON_CLICKED as nt}from"./widgets/adw-toast-overlay.js";import{AdwAlertResponses as rt,NOTIFY_RESPONSE as it}from"./widgets/adw-alert-dialog.js";import{CLOSED as at}from"./widgets/adw-about-dialog.js";import{CLOSED as ot}from"./widgets/adw-preferences-dialog.js";import{AdwBreakpoint as st,addBreakpoints as ct,evaluateBreakpointCondition as lt,parseBreakpointCondition as ut}from"./widgets/breakpoint.js";import{registerAdwaitaElements as $}from"./widgets/index.js";import{adw_exports as dt}from"./namespace/adw.js";import{gtk_exports as ft}from"./namespace/gtk.js";import{assertNativeScript as pt,assertNativeScript as mt,isAndroid as ht,isIOS as gt,isNativeScript as _t}from"@gjsify/native-platform";function registerAdwaita(){mt(),$()}export{at as ABOUT_CLOSED,i as ACTIVATED,f as ADWAITA_ICON_GRID,we as ADWAITA_NS_ACCENT_RULES,ee as ADWAITA_SANS_FONT_FAMILY,te as ADWAITA_SANS_TTF_FILES,ce as AVATAR_DEFAULT_ICON,dt as Adw,rt as AdwAlertResponses,st as AdwBreakpoint,ve as AdwDataGrid,O as AdwImageButton,R as AdwSliderRow,Ye as AdwSplitViewBase,$e as AdwToast,et as AdwToastQueue,Ve as AdwViewSwitcherBase,oe as BUTTON_CLICKED,be as CLICKED,N as ComboState,ue as DATA_GRID_HEADER_CELL_CLASS,de as DATA_GRID_HEADER_ROW_CLASS,Q as DATA_GRID_SECTION_CELL_CLASS,le as DEFAULT_AVATAR_SIZE,J as DEFAULT_BOX_SPACING,Ue as DEFAULT_CAROUSEL_PAGE_WIDTH,ie as DEFAULT_CLAMP_MAX_SIZE,E as DEFAULT_GTK_IMAGE_SIZE,k as DEFAULT_ICON_BUTTON_ICON_SIZE,p as DEFAULT_ICON_COLOR,m as DEFAULT_ICON_COLOR_DARK,ae as DEFAULT_SPINNER_SIZE,tt as DEFAULT_TOAST_TIMEOUT,j as ENTRY_ACTIVATE,B as ExpanderState,t as GTK_ALIGN,K as GTK_BUTTON_CLICKED,q as GTK_BUTTON_LABEL_CLASS,ft as Gtk,_ as ICON_FALLBACK_NAME,re as MENU_ITEM_ACTIVATED,xe as MENU_TAPPED,a as NOTIFY_ACTIVE,F as NOTIFY_DROP_DOWN_SELECTED,M as NOTIFY_ENTRY_TEXT,V as NOTIFY_EXPANDED,Qe as NOTIFY_OPEN,We as NOTIFY_POSITION,it as NOTIFY_RESPONSE,P as NOTIFY_SELECTED,Xe as NOTIFY_SHOW_SIDEBAR,Ze as NOTIFY_SIDEBAR_SELECTED,z as NOTIFY_SLIDER_VALUE,A as NOTIFY_TEXT,Se as NOTIFY_TOGGLE_SELECTED,I as NOTIFY_VALUE,He as NOTIFY_VIEW_SELECTED,Be as NOTIFY_VISIBLE_CHILD,Ge as NOTIFY_VISIBLE_PAGE,Ke as NsNavigationSplitViewState,qe as NsOverlaySplitViewState,ot as PREFERENCES_CLOSED,ye as ROW_ACTIVATED,ke as SHORTCUT_LABEL_CAP_TEXT_CLASS,Ae as SHORTCUT_LABEL_CLASS,je as SHORTCUT_LABEL_DIMMED_CLASS,Me as SHORTCUT_LABEL_DISABLED_CLASS,Ne as SHORTCUT_LABEL_KEYCAP_CLASS,Pe as SHORTCUT_LABEL_KEYS_CLASS,Fe as SHORTCUT_LABEL_SIDE_CLASS,Ie as SHORTCUT_LABEL_SPACED_CLASS,L as SpinState,nt as TOAST_BUTTON_CLICKED,Ce as ToggleGroupState,ct as addBreakpoints,o as adwaitaColorScheme,ne as adwaitaFontInstallInstructions,Te as adwaitaNsAccentColor,Ee as adwaitaNsAccentCss,De as applyAdwaitaNsAccent,n as applyConstructProps,pt as assertNativeScript,D as attachRowPressFeedback,se as avatarInitials,Y as boxChildMargin,X as boxSpacingChanges,H as buttonSlotAfterWrite,U as buttonSlotDetaches,Oe as clearAdwaitaNsAccent,v as compiledIconNames,fe as dataGridCellClass,pe as dataGridItemSpec,me as dataGridRowClass,he as dataGridShapeKey,ge as dataGridTracksKey,lt as evaluateBreakpointCondition,h as extractIconPaths,g as extractPathData,e as hasAdwaitaSans,y as iconValueKind,ht as isAndroid,gt as isIOS,b as isIconAvailable,_t as isNativeScript,s as isThemeIconColor,W as labelDisplayText,G as labelMarkupIsUnparseable,Z as normalizeBoxSpacing,r as nsAlignment,c as onAdwaitaColorSchemeChanged,ut as parseBreakpointCondition,_e as parseDataGridWidth,registerAdwaita,$ as registerAdwaitaElements,x as registerIcon,S as registeredIconNames,T as renderSymbolicIcon,C as resolveIconSource,l as setAdwaitaColorScheme,Le as shortcutLabelDirection,Re as shortcutLabelPlatform,ze as shortcutLabelRenderPlan,Je as splitViewColumns,u as themeIconColor,d as toggleAdwaitaColorScheme,w as unregisterIcon};
1
+ import"./_virtual/_rolldown/runtime.js";import{ADWAITA_SANS_FONT_FAMILY as ee,ADWAITA_SANS_TTF_FILES as te,adwaitaFontInstallInstructions as ne,hasAdwaitaSans as e}from"./fonts.js";import{GTK_ALIGN as t}from"./widgets/gtk-align.js";import{DEFAULT_ICON_PIXEL_SIZE as n,GTK_ICON_SIZE_NICKS as r,GTK_ICON_SIZE_PIXELS as i,PIXEL_SIZE_UNSET as a,isGtkIconSizeNick as o}from"./widgets/gtk-icon-size.js";import{applyConstructProps as s,nsAlignment as c}from"./widgets/construct-props.js";import{ACTIVATED as l}from"./widgets/adw-action-row.js";import{NOTIFY_ACTIVE as u}from"./widgets/adw-switch-row.js";import{adwaitaColorScheme as d,isThemeIconColor as f,onAdwaitaColorSchemeChanged as p,setAdwaitaColorScheme as m,themeIconColor as h,toggleAdwaitaColorScheme as g}from"./widgets/color-scheme.js";import{ADWAITA_ICON_GRID as _,DEFAULT_ICON_COLOR as v,DEFAULT_ICON_COLOR_DARK as y,extractIconPaths as b,extractPathData as x}from"./widgets/icon-path.js";import{ICON_FALLBACK_NAME as S,compiledIconNames as C,iconValueKind as w,isIconAvailable as T,registerIcon as E,registeredIconNames as D,resolveIconSource as O,unregisterIcon as k}from"./widgets/icon-theme.js";import{renderSymbolicIcon as A}from"./widgets/icons.js";import{DEFAULT_GTK_IMAGE_SIZE as j}from"./widgets/gtk-image.js";import{attachRowPressFeedback as M}from"./widgets/row-press.js";import{AdwImageButton as N,DEFAULT_ICON_BUTTON_ICON_SIZE as P}from"./widgets/adw-image-button.js";import{NOTIFY_TEXT as F}from"./widgets/adw-entry-row.js";import{ACTIVATE as I,NOTIFY_TEXT as L}from"./widgets/gtk-entry.js";import{ComboState as R,NOTIFY_SELECTED as z}from"./widgets/adw-combo-row.js";import{NOTIFY_SELECTED as B}from"./widgets/gtk-drop-down.js";import{NOTIFY_VALUE as V,SpinState as H}from"./widgets/adw-spin-row.js";import{AdwSliderRow as U,NOTIFY_SLIDER_VALUE as W}from"./widgets/adw-slider-row.js";import{ExpanderState as G,NOTIFY_EXPANDED as K}from"./widgets/adw-expander-row.js";import{buttonSlotAfterWrite as q,buttonSlotDetaches as J}from"./widgets/button-slot.js";import{labelDisplayText as Y,labelMarkupIsUnparseable as X}from"./widgets/label-text.js";import{GTK_BUTTON_CLICKED as Z,GTK_BUTTON_LABEL_CLASS as re}from"./widgets/gtk-button.js";import{DEFAULT_BOX_SPACING as ie,boxChildMargin as ae,boxSpacingChanges as oe,normalizeBoxSpacing as se}from"./widgets/box-layout.js";import{MENU_ITEM_ACTIVATED as ce}from"./widgets/gtk-menu-button.js";import{DEFAULT_CLAMP_MAX_SIZE as le,DEFAULT_SPINNER_SIZE as ue}from"./widgets/chrome.js";import{BUTTON_CLICKED as de}from"./widgets/adw-banner.js";import{avatarInitials as fe}from"./widgets/avatar-color.js";import{AVATAR_DEFAULT_ICON as pe}from"./widgets/avatar-view.js";import{DEFAULT_AVATAR_SIZE as me}from"./widgets/adw-avatar.js";import{DATA_GRID_HEADER_CELL_CLASS as he,DATA_GRID_HEADER_ROW_CLASS as ge,DATA_GRID_SECTION_CELL_CLASS as _e,dataGridCellClass as ve,dataGridItemSpec as ye,dataGridRowClass as Q,dataGridShapeKey as be,dataGridTracksKey as xe,parseDataGridWidth as Se}from"./widgets/data-grid-model.js";import{AdwDataGrid as Ce,ROW_ACTIVATED as we}from"./widgets/adw-data-grid.js";import{CLICKED as Te,MENU_TAPPED as Ee}from"./widgets/adw-split-button.js";import{NOTIFY_SELECTED as De,ToggleGroupState as Oe}from"./widgets/adw-toggle-group.js";import{ADWAITA_NS_ACCENT_RULES as ke,adwaitaNsAccentColor as Ae,adwaitaNsAccentCss as je}from"./widgets/accent-theme.js";import{applyAdwaitaNsAccent as Me,clearAdwaitaNsAccent as Ne}from"./widgets/adw-accent.js";import{SHORTCUT_LABEL_CAP_TEXT_CLASS as Pe,SHORTCUT_LABEL_CLASS as Fe,SHORTCUT_LABEL_DIMMED_CLASS as Ie,SHORTCUT_LABEL_DISABLED_CLASS as Le,SHORTCUT_LABEL_KEYCAP_CLASS as Re,SHORTCUT_LABEL_KEYS_CLASS as ze,SHORTCUT_LABEL_SIDE_CLASS as Be,SHORTCUT_LABEL_SPACED_CLASS as Ve,shortcutLabelDirection as He,shortcutLabelPlatform as Ue,shortcutLabelRenderPlan as We}from"./widgets/shortcut-label.js";import{NOTIFY_VISIBLE_CHILD as Ge}from"./widgets/adw-view-stack.js";import{AdwViewSwitcherBase as Ke,NOTIFY_SELECTED as qe}from"./widgets/view-switcher-base.js";import{DEFAULT_CAROUSEL_PAGE_WIDTH as Je}from"./widgets/carousel-state.js";import{NOTIFY_POSITION as Ye}from"./widgets/adw-carousel.js";import{NOTIFY_VISIBLE_PAGE as Xe}from"./widgets/navigation-stack.js";import{NsNavigationSplitViewState as Ze,NsOverlaySplitViewState as Qe,splitViewColumns as $e}from"./widgets/split-view-state.js";import{AdwSplitViewBase as et,NOTIFY_SHOW_SIDEBAR as tt}from"./widgets/split-view-base.js";import{NOTIFY_SELECTED as nt}from"./widgets/adw-sidebar.js";import{NOTIFY_OPEN as rt}from"./widgets/bottom-sheet-state.js";import{AdwToast as it,AdwToastQueue as at,DEFAULT_TOAST_TIMEOUT as ot,TOAST_BUTTON_CLICKED as st}from"./widgets/adw-toast-overlay.js";import{AdwAlertResponses as ct,NOTIFY_RESPONSE as lt}from"./widgets/adw-alert-dialog.js";import{CLOSED as ut}from"./widgets/adw-about-dialog.js";import{CLOSED as dt}from"./widgets/adw-preferences-dialog.js";import{AdwBreakpoint as ft,addBreakpoints as pt,evaluateBreakpointCondition as mt,parseBreakpointCondition as ht}from"./widgets/breakpoint.js";import{registerAdwaitaElements as $}from"./widgets/index.js";import{adw_exports as gt}from"./namespace/adw.js";import{gtk_exports as _t}from"./namespace/gtk.js";import{assertNativeScript as vt,assertNativeScript as yt,isAndroid as bt,isIOS as xt,isNativeScript as St}from"@gjsify/native-platform";function registerAdwaita(){yt(),$()}export{ut as ABOUT_CLOSED,l as ACTIVATED,_ as ADWAITA_ICON_GRID,ke as ADWAITA_NS_ACCENT_RULES,ee as ADWAITA_SANS_FONT_FAMILY,te as ADWAITA_SANS_TTF_FILES,pe as AVATAR_DEFAULT_ICON,gt as Adw,ct as AdwAlertResponses,ft as AdwBreakpoint,Ce as AdwDataGrid,N as AdwImageButton,U as AdwSliderRow,et as AdwSplitViewBase,it as AdwToast,at as AdwToastQueue,Ke as AdwViewSwitcherBase,de as BUTTON_CLICKED,Te as CLICKED,R as ComboState,he as DATA_GRID_HEADER_CELL_CLASS,ge as DATA_GRID_HEADER_ROW_CLASS,_e as DATA_GRID_SECTION_CELL_CLASS,me as DEFAULT_AVATAR_SIZE,ie as DEFAULT_BOX_SPACING,Je as DEFAULT_CAROUSEL_PAGE_WIDTH,le as DEFAULT_CLAMP_MAX_SIZE,j as DEFAULT_GTK_IMAGE_SIZE,P as DEFAULT_ICON_BUTTON_ICON_SIZE,v as DEFAULT_ICON_COLOR,y as DEFAULT_ICON_COLOR_DARK,n as DEFAULT_ICON_PIXEL_SIZE,ue as DEFAULT_SPINNER_SIZE,ot as DEFAULT_TOAST_TIMEOUT,I as ENTRY_ACTIVATE,G as ExpanderState,t as GTK_ALIGN,Z as GTK_BUTTON_CLICKED,re as GTK_BUTTON_LABEL_CLASS,r as GTK_ICON_SIZE_NICKS,i as GTK_ICON_SIZE_PIXELS,_t as Gtk,S as ICON_FALLBACK_NAME,ce as MENU_ITEM_ACTIVATED,Ee as MENU_TAPPED,u as NOTIFY_ACTIVE,B as NOTIFY_DROP_DOWN_SELECTED,L as NOTIFY_ENTRY_TEXT,K as NOTIFY_EXPANDED,rt as NOTIFY_OPEN,Ye as NOTIFY_POSITION,lt as NOTIFY_RESPONSE,z as NOTIFY_SELECTED,tt as NOTIFY_SHOW_SIDEBAR,nt as NOTIFY_SIDEBAR_SELECTED,W as NOTIFY_SLIDER_VALUE,F as NOTIFY_TEXT,De as NOTIFY_TOGGLE_SELECTED,V as NOTIFY_VALUE,qe as NOTIFY_VIEW_SELECTED,Ge as NOTIFY_VISIBLE_CHILD,Xe as NOTIFY_VISIBLE_PAGE,Ze as NsNavigationSplitViewState,Qe as NsOverlaySplitViewState,a as PIXEL_SIZE_UNSET,dt as PREFERENCES_CLOSED,we as ROW_ACTIVATED,Pe as SHORTCUT_LABEL_CAP_TEXT_CLASS,Fe as SHORTCUT_LABEL_CLASS,Ie as SHORTCUT_LABEL_DIMMED_CLASS,Le as SHORTCUT_LABEL_DISABLED_CLASS,Re as SHORTCUT_LABEL_KEYCAP_CLASS,ze as SHORTCUT_LABEL_KEYS_CLASS,Be as SHORTCUT_LABEL_SIDE_CLASS,Ve as SHORTCUT_LABEL_SPACED_CLASS,H as SpinState,st as TOAST_BUTTON_CLICKED,Oe as ToggleGroupState,pt as addBreakpoints,d as adwaitaColorScheme,ne as adwaitaFontInstallInstructions,Ae as adwaitaNsAccentColor,je as adwaitaNsAccentCss,Me as applyAdwaitaNsAccent,s as applyConstructProps,vt as assertNativeScript,M as attachRowPressFeedback,fe as avatarInitials,ae as boxChildMargin,oe as boxSpacingChanges,q as buttonSlotAfterWrite,J as buttonSlotDetaches,Ne as clearAdwaitaNsAccent,C as compiledIconNames,ve as dataGridCellClass,ye as dataGridItemSpec,Q as dataGridRowClass,be as dataGridShapeKey,xe as dataGridTracksKey,mt as evaluateBreakpointCondition,b as extractIconPaths,x as extractPathData,e as hasAdwaitaSans,w as iconValueKind,bt as isAndroid,o as isGtkIconSizeNick,xt as isIOS,T as isIconAvailable,St as isNativeScript,f as isThemeIconColor,Y as labelDisplayText,X as labelMarkupIsUnparseable,se as normalizeBoxSpacing,c as nsAlignment,p as onAdwaitaColorSchemeChanged,ht as parseBreakpointCondition,Se as parseDataGridWidth,registerAdwaita,$ as registerAdwaitaElements,E as registerIcon,D as registeredIconNames,A as renderSymbolicIcon,O as resolveIconSource,m as setAdwaitaColorScheme,He as shortcutLabelDirection,Ue as shortcutLabelPlatform,We as shortcutLabelRenderPlan,$e as splitViewColumns,h as themeIconColor,g as toggleAdwaitaColorScheme,k as unregisterIcon};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{xmlBoolean as e,xmlNumber as t}from"./xml-values.js";import{applyConstructProps as n}from"./construct-props.js";import{withSignals as r}from"./signals.js";import{GtkImage as i}from"./gtk-image.js";import{avatarColor as a,avatarInitials as o}from"./avatar-color.js";import{AVATAR_DEFAULT_ICON as s,avatarViewState as c}from"./avatar-view.js";import{GridLayout as l,ItemSpec as u,Label as d}from"@nativescript/core";import{avatarIconSize as f,avatarMaxFontSize as p}from"@gjsify/adwaita-core";const m=48;var AdwAvatar=class extends r(l){_label;_icon;_text=``;_size=48;_showInitials=!1;_iconName=``;constructor(e){super(),this.className=`adw-avatar`,this.addColumn(new u(1,`star`)),this.addRow(new u(1,`star`));let t=new d;t.className=`adw-avatar-label`,t.horizontalAlignment=`center`,t.verticalAlignment=`middle`,l.setColumn(t,0),l.setRow(t,0),this.addChild(t),this._label=t;let r=new i;r.className=`adw-icon adw-avatar-icon`,r.horizontalAlignment=`center`,r.verticalAlignment=`middle`,l.setColumn(r,0),l.setRow(r,0),this.addChild(r),this._icon=r,this._applySize(),this._applyColor(),this._applyMode(),n(this,e)}_applySize(){this.width=this._size,this.height=this._size,this.set(`borderRadius`,this._size/2),this._label.set(`fontSize`,Math.round(Math.min(this._size*.4,p(this._size)))),this._icon.iconSize=f(this._size)}_applyColor(){let{fill:e,fg:t}=a(this._text);this.set(`backgroundColor`,e),this._label.set(`color`,t),this._icon.iconColor=t}_applyMode(){let e=c({showInitials:this._showInitials,text:this._text,iconName:this._iconName});this._label.visibility=e.label,this._icon.visibility=e.icon,e.icon===`visible`&&(this._icon.iconName=e.iconName)}get text(){return this._text}set text(e){this._text=e??``,this._label.text=o(this._text),this._applyColor(),this._applyMode()}get size(){return this._size}set size(e){let n=t(e,48);this._size=n>0?n:48,this._applySize()}get showInitials(){return this._showInitials}set showInitials(t){this._showInitials=e(t,!1),this._applyMode()}get iconName(){return this._iconName}set iconName(e){this._iconName=e??``,this._applyMode()}};export{s as AVATAR_DEFAULT_ICON,AdwAvatar,m as DEFAULT_AVATAR_SIZE,a as avatarColor,o as avatarInitials};
1
+ import"../_virtual/_rolldown/runtime.js";import{xmlBoolean as e,xmlNumber as t}from"./xml-values.js";import{applyConstructProps as n}from"./construct-props.js";import{withSignals as r}from"./signals.js";import{GtkImage as i}from"./gtk-image.js";import{avatarColor as a,avatarInitials as o}from"./avatar-color.js";import{AVATAR_DEFAULT_ICON as s,avatarViewState as c}from"./avatar-view.js";import{GridLayout as l,ItemSpec as u,Label as d}from"@nativescript/core";import{avatarIconSize as f,avatarMaxFontSize as p}from"@gjsify/adwaita-core";const m=48;var AdwAvatar=class extends r(l){_label;_icon;_text=``;_size=48;_showInitials=!1;_iconName=``;constructor(e){super(),this.className=`adw-avatar`,this.addColumn(new u(1,`star`)),this.addRow(new u(1,`star`));let t=new d;t.className=`adw-avatar-label`,t.horizontalAlignment=`center`,t.verticalAlignment=`middle`,l.setColumn(t,0),l.setRow(t,0),this.addChild(t),this._label=t;let r=new i;r.className=`adw-icon adw-avatar-icon`,r.horizontalAlignment=`center`,r.verticalAlignment=`middle`,l.setColumn(r,0),l.setRow(r,0),this.addChild(r),this._icon=r,this._applySize(),this._applyColor(),this._applyMode(),n(this,e)}_applySize(){this.width=this._size,this.height=this._size,this.set(`borderRadius`,this._size/2),this._label.set(`fontSize`,Math.round(Math.min(this._size*.4,p(this._size)))),this._icon.pixelSize=f(this._size)}_applyColor(){let{fill:e,fg:t}=a(this._text);this.set(`backgroundColor`,e),this._label.set(`color`,t),this._icon.iconColor=t}_applyMode(){let e=c({showInitials:this._showInitials,text:this._text,iconName:this._iconName});this._label.visibility=e.label,this._icon.visibility=e.icon,e.icon===`visible`&&(this._icon.iconName=e.iconName)}get text(){return this._text}set text(e){this._text=e??``,this._label.text=o(this._text),this._applyColor(),this._applyMode()}get size(){return this._size}set size(e){let n=t(e,48);this._size=n>0?n:48,this._applySize()}get showInitials(){return this._showInitials}set showInitials(t){this._showInitials=e(t,!1),this._applyMode()}get iconName(){return this._iconName}set iconName(e){this._iconName=e??``,this._applyMode()}};export{s as AVATAR_DEFAULT_ICON,AdwAvatar,m as DEFAULT_AVATAR_SIZE,a as avatarColor,o as avatarInitials};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{AdwActionRow as n}from"./adw-action-row.js";import{GtkImage as r}from"./gtk-image.js";import{attachRowPressFeedback as i}from"./row-press.js";import{Label as a,StackLayout as o,action as s}from"@nativescript/core";import{ComboState as c,ComboState as l,normalizeComboOptions as u}from"@gjsify/adwaita-core";import{panDownSymbolic as d}from"@gjsify/adwaita-icons/ui";const f=`notify::selected`;var AdwComboRow=class extends n{_valueLabel;_chevron;_state=new l;constructor(e){super(),this.className=`adw-row adw-action-row adw-combo-row`;let n=new o;n.orientation=`horizontal`,n.className=`adw-combo-suffix`;let s=new a;s.className=`adw-combo-value`,s.text=``;let c=new r;c.className=`adw-combo-chevron`,c.iconColor=`#9a9a9a`,c.iconSize=16,c.iconName=d,n.addChild(s),n.addChild(c),this.add_suffix(n),this._valueLabel=s,this._chevron=c,this._state.subscribe(e=>{if(this._valueLabel.text=e.label,this._syncChooser(),e.interactive){let t={eventName:f,object:this,selected:e.selected,value:e.value};this.notify(t)}}),this.addEventListener(`tap`,()=>{this._openChooser()}),i(this),this._syncChooser(),t(this,e)}_syncChooser(){this._chevron.visibility=this._state.presentsChooser?`visible`:`collapse`}async _openChooser(){if(!this._state.presentsChooser)return;let e=this._state.model.map(e=>e.label),t=await s({title:this.title||void 0,cancelButtonText:`Cancel`,actions:e});this._state.select(e.indexOf(t))}get model(){return this._state.model}set model(e){this._state.setModel(u(e))}get selected(){return this._state.selectedIndex}set selected(t){let n=e(t,this.selected);this._state.setSelectedIndex(n)}get selectedValue(){return this._state.selectedValue}set selectedValue(e){this._state.setSelectedValue(e)}};export{AdwComboRow,c as ComboState,f as NOTIFY_SELECTED};
1
+ import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{AdwActionRow as n}from"./adw-action-row.js";import{GtkImage as r}from"./gtk-image.js";import{attachRowPressFeedback as i}from"./row-press.js";import{Label as a,StackLayout as o,action as s}from"@nativescript/core";import{ComboState as c,ComboState as l,normalizeComboOptions as u}from"@gjsify/adwaita-core";import{panDownSymbolic as d}from"@gjsify/adwaita-icons/ui";const f=`notify::selected`;var AdwComboRow=class extends n{_valueLabel;_chevron;_state=new l;constructor(e){super(),this.className=`adw-row adw-action-row adw-combo-row`;let n=new o;n.orientation=`horizontal`,n.className=`adw-combo-suffix`;let s=new a;s.className=`adw-combo-value`,s.text=``;let c=new r;c.className=`adw-combo-chevron`,c.iconColor=`#9a9a9a`,c.pixelSize=16,c.iconName=d,n.addChild(s),n.addChild(c),this.add_suffix(n),this._valueLabel=s,this._chevron=c,this._state.subscribe(e=>{if(this._valueLabel.text=e.label,this._syncChooser(),e.interactive){let t={eventName:f,object:this,selected:e.selected,value:e.value};this.notify(t)}}),this.addEventListener(`tap`,()=>{this._openChooser()}),i(this),this._syncChooser(),t(this,e)}_syncChooser(){this._chevron.visibility=this._state.presentsChooser?`visible`:`collapse`}async _openChooser(){if(!this._state.presentsChooser)return;let e=this._state.model.map(e=>e.label),t=await s({title:this.title||void 0,cancelButtonText:`Cancel`,actions:e});this._state.select(e.indexOf(t))}get model(){return this._state.model}set model(e){this._state.setModel(u(e))}get selected(){return this._state.selectedIndex}set selected(t){let n=e(t,this.selected);this._state.setSelectedIndex(n)}get selectedValue(){return this._state.selectedValue}set selectedValue(e){this._state.setSelectedValue(e)}};export{AdwComboRow,c as ComboState,f as NOTIFY_SELECTED};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{withSignals as n}from"./signals.js";import{onAdwaitaColorSchemeChanged as r,themeIconColor as i}from"./color-scheme.js";import{DEFAULT_ICON_COLOR as a}from"./icon-path.js";import{resolveIconSource as o}from"./icon-theme.js";import{renderSymbolicIcon as s}from"./icons.js";import{attachRowPressFeedback as c}from"./row-press.js";import{GridLayout as l,Image as u,ItemSpec as d}from"@nativescript/core";const f=16;var AdwImageButton=class extends n(l){_image;_icon=``;_iconColor=i();_explicitColor=!1;_iconSize=16;_unsubScheme=null;constructor(e){super(),this.className=`adw-image-button`,this.addRow(new d(1,`star`)),this.addColumn(new d(1,`star`));let n=new u;n.className=`adw-image-button-icon`,n.stretch=`aspectFit`,n.width=this._iconSize,n.height=this._iconSize,n.horizontalAlignment=`center`,n.verticalAlignment=`middle`,this.addChild(n),this._image=n,c(this),this.addEventListener(`loaded`,()=>{this._syncThemeColor(),this._unsubScheme??=r(()=>this._syncThemeColor())}),this.addEventListener(`unloaded`,()=>{this._unsubScheme?.(),this._unsubScheme=null}),t(this,e)}_syncThemeColor(){if(this._explicitColor)return;let e=i();e!==this._iconColor&&(this._iconColor=e,this._render())}_render(){let e=o(this._icon);if(!e)return;let t=s(e,{size:this._iconSize,color:this._iconColor});t&&(this._image.imageSource=t)}get iconName(){return this._icon}set iconName(e){this._icon=e??``,this._image.width=this._iconSize,this._image.height=this._iconSize,this._render()}get iconColor(){return this._iconColor}set iconColor(e){this._explicitColor=!0,this._iconColor=e||a,this._render()}get iconSize(){return this._iconSize}set iconSize(t){let n=e(t,this.iconSize);this._iconSize=Number.isFinite(n)&&n>0?n:16,this._image.width=this._iconSize,this._image.height=this._iconSize,this._render()}get image(){return this._image}};export{AdwImageButton,f as DEFAULT_ICON_BUTTON_ICON_SIZE};
1
+ import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{DEFAULT_ICON_PIXEL_SIZE as t,gtkIconSizeNick as n,iconPixelSize as r,storedPixelSize as i}from"./gtk-icon-size.js";import{applyConstructProps as a}from"./construct-props.js";import{withSignals as o}from"./signals.js";import{onAdwaitaColorSchemeChanged as s,themeIconColor as c}from"./color-scheme.js";import{DEFAULT_ICON_COLOR as l}from"./icon-path.js";import{resolveIconSource as u}from"./icon-theme.js";import{renderSymbolicIcon as d}from"./icons.js";import{attachRowPressFeedback as f}from"./row-press.js";import{GridLayout as p,Image as m,ItemSpec as h}from"@nativescript/core";const g=t;var AdwImageButton=class extends o(p){_image;_icon=``;_iconColor=c();_explicitColor=!1;_iconSize=`inherit`;_pixelSize=-1;_unsubScheme=null;constructor(e){super(),this.className=`adw-image-button`,this.addRow(new h(1,`star`)),this.addColumn(new h(1,`star`));let t=new m;t.className=`adw-image-button-icon`,t.stretch=`aspectFit`,t.width=this._renderedSize,t.height=this._renderedSize,t.horizontalAlignment=`center`,t.verticalAlignment=`middle`,this.addChild(t),this._image=t,f(this),this.addEventListener(`loaded`,()=>{this._syncThemeColor(),this._unsubScheme??=s(()=>this._syncThemeColor())}),this.addEventListener(`unloaded`,()=>{this._unsubScheme?.(),this._unsubScheme=null}),a(this,e)}_syncThemeColor(){if(this._explicitColor)return;let e=c();e!==this._iconColor&&(this._iconColor=e,this._render())}get _renderedSize(){return r(this._iconSize,this._pixelSize)}_applySize(){let e=this._renderedSize;this._image.width=e,this._image.height=e,this._render()}_render(){let e=u(this._icon);if(!e)return;let t=d(e,{size:this._renderedSize,color:this._iconColor});t&&(this._image.imageSource=t)}get iconName(){return this._icon}set iconName(e){this._icon=e??``,this._applySize()}get iconColor(){return this._iconColor}set iconColor(e){this._explicitColor=!0,this._iconColor=e||l,this._render()}get iconSize(){return this._iconSize}set iconSize(e){this._iconSize=n(e,this._iconSize),this._applySize()}get pixelSize(){return this._pixelSize}set pixelSize(t){this._pixelSize=i(e(t,this._pixelSize)),this._applySize()}get image(){return this._image}};export{AdwImageButton,g as DEFAULT_ICON_BUTTON_ICON_SIZE};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{applyConstructProps as e}from"./construct-props.js";import{withSignals as t}from"./signals.js";import{GtkImage as n}from"./gtk-image.js";import{statusPageIconVisibility as r,statusPageLabelVisibility as i}from"./status-page-content.js";import{GridLayout as a,ItemSpec as o,Label as s,StackLayout as c}from"@nativescript/core";var AdwStatusPage=class extends t(a){_stack;_icon;_iconName=``;_iconLabel;_iconGlyph=``;_titleLabel;_descriptionLabel;_child=null;constructor(t){super(),this.className=`adw-status-page`,this.addColumn(new o(1,`star`)),this.addRow(new o(1,`star`));let l=new c;l.orientation=`vertical`,l.className=`adw-status-page-content`,l.horizontalAlignment=`center`,l.verticalAlignment=`middle`,a.setColumn(l,0),a.setRow(l,0),this.addChild(l),this._stack=l;let u=new n;u.className=`${u.className} adw-status-page-icon`.trim(),u.horizontalAlignment=`center`,u.iconColor=`#9b9b9b`,u.iconSize=96,u.visibility=r(this._iconName),this._icon=u;let d=new s;d.className=`adw-status-page-icon-glyph`,d.horizontalAlignment=`center`,d.visibility=r(this._iconGlyph),this._iconLabel=d;let f=new s;f.className=`adw-status-page-title`,f.horizontalAlignment=`center`,f.textWrap=!0,f.visibility=i(f.text),this._titleLabel=f;let p=new s;p.className=`adw-status-page-description`,p.horizontalAlignment=`center`,p.textWrap=!0,p.visibility=i(p.text),this._descriptionLabel=p;for(let e of[u,d,f,p])l.addChild(e);e(this,t)}get iconName(){return this._iconName}set iconName(e){this._iconName=e??``,this._icon.iconName=this._iconName,this._icon.visibility=r(this._iconName),this._iconLabel.visibility=`collapse`}get iconText(){return this._iconGlyph}set iconText(e){this._iconGlyph=e??``,this._iconLabel.text=this._iconGlyph,this._iconLabel.visibility=r(this._iconGlyph),this._icon.visibility=`collapse`}get iconColor(){return this._icon.iconColor}set iconColor(e){this._icon.iconColor=e}get title(){return this._titleLabel.text??``}set title(e){let t=e??``;this._titleLabel.text=t,this._titleLabel.visibility=i(t)}get description(){return this._descriptionLabel.text??``}set description(e){let t=e??``;this._descriptionLabel.text=t,this._descriptionLabel.visibility=i(t)}set_child(e){this._child&&=(this._stack.removeChild(this._child),null),e&&(e.className=`${e.className??``} adw-status-page-child`.trim(),e.horizontalAlignment=`center`,this._stack.addChild(e),this._child=e)}get child(){return this._child}_addChildFromBuilder(e,t){this.set_child(t)}};export{AdwStatusPage};
1
+ import"../_virtual/_rolldown/runtime.js";import{applyConstructProps as e}from"./construct-props.js";import{withSignals as t}from"./signals.js";import{GtkImage as n}from"./gtk-image.js";import{statusPageIconVisibility as r,statusPageLabelVisibility as i}from"./status-page-content.js";import{GridLayout as a,ItemSpec as o,Label as s,StackLayout as c}from"@nativescript/core";var AdwStatusPage=class extends t(a){_stack;_icon;_iconName=``;_iconLabel;_iconGlyph=``;_titleLabel;_descriptionLabel;_child=null;constructor(t){super(),this.className=`adw-status-page`,this.addColumn(new o(1,`star`)),this.addRow(new o(1,`star`));let l=new c;l.orientation=`vertical`,l.className=`adw-status-page-content`,l.horizontalAlignment=`center`,l.verticalAlignment=`middle`,a.setColumn(l,0),a.setRow(l,0),this.addChild(l),this._stack=l;let u=new n;u.className=`${u.className} adw-status-page-icon`.trim(),u.horizontalAlignment=`center`,u.iconColor=`#9b9b9b`,u.pixelSize=96,u.visibility=r(this._iconName),this._icon=u;let d=new s;d.className=`adw-status-page-icon-glyph`,d.horizontalAlignment=`center`,d.visibility=r(this._iconGlyph),this._iconLabel=d;let f=new s;f.className=`adw-status-page-title`,f.horizontalAlignment=`center`,f.textWrap=!0,f.visibility=i(f.text),this._titleLabel=f;let p=new s;p.className=`adw-status-page-description`,p.horizontalAlignment=`center`,p.textWrap=!0,p.visibility=i(p.text),this._descriptionLabel=p;for(let e of[u,d,f,p])l.addChild(e);e(this,t)}get iconName(){return this._iconName}set iconName(e){this._iconName=e??``,this._icon.iconName=this._iconName,this._icon.visibility=r(this._iconName),this._iconLabel.visibility=`collapse`}get iconText(){return this._iconGlyph}set iconText(e){this._iconGlyph=e??``,this._iconLabel.text=this._iconGlyph,this._iconLabel.visibility=r(this._iconGlyph),this._icon.visibility=`collapse`}get iconColor(){return this._icon.iconColor}set iconColor(e){this._icon.iconColor=e}get title(){return this._titleLabel.text??``}set title(e){let t=e??``;this._titleLabel.text=t,this._titleLabel.visibility=i(t)}get description(){return this._descriptionLabel.text??``}set description(e){let t=e??``;this._descriptionLabel.text=t,this._descriptionLabel.visibility=i(t)}set_child(e){this._child&&=(this._stack.removeChild(this._child),null),e&&(e.className=`${e.className??``} adw-status-page-child`.trim(),e.horizontalAlignment=`center`,this._stack.addChild(e),this._child=e)}get child(){return this._child}_addChildFromBuilder(e,t){this.set_child(t)}};export{AdwStatusPage};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{xmlBoolean as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{withSignals as n}from"./signals.js";import{GtkImage as r}from"./gtk-image.js";import{attachRowPressFeedback as i}from"./row-press.js";import{AdwImageButton as a}from"./adw-image-button.js";import{applyTabViewVisibility as o,createTabViewState as s,tabBarVisibility as c,tabCloseVisibilities as l,tabLabelText as u,tabViewNotifyPayload as d}from"./tab-view-state.js";import{GridLayout as f,ItemSpec as p,Label as m,StackLayout as h}from"@nativescript/core";import{tabIconState as g}from"@gjsify/adwaita-core";import{windowCloseSymbolic as _}from"@gjsify/adwaita-icons/ui";const v=`notify::selected-page`,y=`pages-changed`,b=`close-page`;var AdwTabView=class extends n(f){_state=s({onClosePage:e=>this._requestClose(e)});_bar;_contentArea;_chips=new Map;_autohide=!1;_defaultIcon=null;_generatedIds=0;closeHandler=null;constructor(e){super(),this.className=`adw-tab-view`,this.addColumn(new p(1,`star`)),this.addRow(new p(1,`auto`)),this.addRow(new p(1,`star`));let n=new h;n.orientation=`horizontal`,n.horizontalAlignment=`stretch`,n.className=`adw-tab-view-bar`,f.setRow(n,0),this.addChild(n),this._bar=n;let r=new f;r.addColumn(new p(1,`star`)),r.addRow(new p(1,`star`)),f.setRow(r,1),this.addChild(r),this._contentArea=r,this._state.subscribePages(e=>this._onPagesChange(e)),this._state.subscribe(e=>{this._applySelection();let t={eventName:v,object:this,...d(e)};this.notify(t)}),t(this,e)}get pages(){return this._state.pages}get nPages(){return this._state.nPages}get nPinnedPages(){return this._state.nPinnedPages}get selectedId(){return this._state.selectedId}get selectedIndex(){return this._state.selectedIndex}get selectedPage(){return this._state.selectedPage}set selectedPage(e){this._state.setSelectedPage(e)}isClosing(e){return this._state.isClosing(e)}set_selected_page(e){return this._state.setSelectedPage(e)}selectNthPage(e){return this._state.selectNthPage(e)}select_previous_page(){return this._state.selectPreviousPage()}select_next_page(){return this._state.selectNextPage()}selectFirstPage(){return this._state.selectFirstPage()}selectLastPage(){return this._state.selectLastPage()}cycleNextPage(){return this._state.cycleNextPage()}cyclePreviousPage(){return this._state.cyclePreviousPage()}addPage(e,t=null){return this._state.addPage(e,t)}insertPage(e,t){return this._state.insertPage(e,t)}prependPage(e){return this._state.prependPage(e)}appendPage(e){return this._state.appendPage(e)}insertPinnedPage(e,t){return this._state.insertPinnedPage(e,t)}prependPinnedPage(e){return this._state.prependPinnedPage(e)}appendPinnedPage(e){return this._state.appendPinnedPage(e)}setPagePinned(e,t){return this._state.setPagePinned(e,t)}closePage(e){return this._state.closePage(e)}closePageFinish(e,t){return this._state.closePageFinish(e,t)}closeOtherPages(e){this._state.closeOtherPages(e)}closePagesBefore(e){this._state.closePagesBefore(e)}closePagesAfter(e){this._state.closePagesAfter(e)}detachPage(e){return this._state.detachPage(e)}reorderPage(e,t){return this._state.reorderPage(e,t)}reorderBackward(e){return this._state.reorderBackward(e)}reorderForward(e){return this._state.reorderForward(e)}reorderFirst(e){return this._state.reorderFirst(e)}reorderLast(e){return this._state.reorderLast(e)}setPageTitle(e,t){return this._state.setPageTitle(e,t)}setPageIcon(e,t){return this._state.setPageIcon(e,t)}setPageLoading(e,t){return this._state.setPageLoading(e,t)}setPageNeedsAttention(e,t){return this._state.setPageNeedsAttention(e,t)}get diagnostics(){return this._state.diagnostics}get autohide(){return this._autohide}set autohide(t){let n=e(t,this.autohide);this._autohide=!!n,this._applyBarVisibility()}get defaultIcon(){return this._defaultIcon}set defaultIcon(e){this._defaultIcon=e;for(let e of this._state.pages)this._refreshChip(e.id)}setViews(e){for(let e of this._state.pages)this._state.detachPage(e.id);for(let t of e)this._state.appendPage({id:this._nextId(),title:t.title,icon:t.icon??null,content:t.content})}get views(){return this._state.pages.map(e=>({title:e.title,content:e.content,icon:e.icon??void 0}))}set views(e){this.setViews(Array.isArray(e)?e:[])}get tabs(){return this.views}set tabs(e){this.views=e}_onPagesChange(e){switch(e.kind){case`attached`:{let t=this._state.getPage(e.id);t&&this._insertChip(t,e.position);break}case`detached`:{let t=this._chips.get(e.id);t&&this._bar.removeChild(t.button),this._chips.delete(e.id);break}case`reordered`:case`pinned`:{let t=this._chips.get(e.id);t&&(this._bar.removeChild(t.button),this._bar.insertChild(t.button,e.position)),this._refreshChip(e.id);break}case`updated`:this._refreshChip(e.id);break}this._applyBarVisibility(),this._applySelection();let t={eventName:y,object:this,...e};this.notify(t)}_insertChip(e,t){let n=new h;n.orientation=`horizontal`,n.className=`adw-tab-view-tab`,n.verticalAlignment=`middle`;let o=new r;o.className=`${o.className} adw-tab-view-tab-icon`.trim(),o.verticalAlignment=`middle`,n.addChild(o);let s=new r;s.className=`${s.className} adw-tab-view-tab-icon`.trim(),s.verticalAlignment=`middle`,n.addChild(s);let c=new m;c.className=`adw-tab-view-tab-label`,c.verticalAlignment=`middle`,n.addChild(c);let l=new a;l.className=`${l.className} adw-tab-close`.trim(),l.iconName=_,l.iconSize=12,l.verticalAlignment=`middle`,l.addEventListener(`tap`,()=>this._state.closePage(e.id)),n.addChild(l),i(n),n.addEventListener(`tap`,()=>this._state.setSelectedPage(e.id)),this._bar.insertChild(n,t),this._chips.set(e.id,{button:n,icon:o,indicator:s,label:c,close:l});let u=e.content;u&&(f.setColumn(u,0),f.setRow(u,0),this._contentArea.addChild(u)),this._refreshChip(e.id)}_refreshChip(e){let t=this._state.getPage(e),n=this._chips.get(e);if(!t||!n)return;n.label.text=u(t),n.label.visibility=t.pinned?`collapse`:`visible`;let r=g(t,this._defaultIcon);n.icon.iconName=r.icon??``,n.icon.visibility=r.iconVisible&&r.icon!==null?`visible`:`collapse`,n.indicator.iconName=t.indicatorIcon??``,n.indicator.visibility=r.indicatorVisible?`visible`:`collapse`}_applySelection(){o(this._state);let e=l(this._state),t=this._state.selectedId;this._state.pages.forEach((n,r)=>{let i=this._chips.get(n.id);i&&(i.button.className=n.id===t?`adw-tab-view-tab active`:`adw-tab-view-tab`,i.close.visibility=e[r])})}_applyBarVisibility(){this._bar.visibility=c(this._state,this._autohide)}_requestClose(e){let t={eventName:b,object:this,id:e.id,index:this._state.getPagePosition(e.id)};return this.notify(t),this.closeHandler?this.closeHandler(e):!e.pinned}_nextId(){return this._generatedIds+=1,`tab-${this._generatedIds}`}};export{AdwTabView,b as CLOSE_PAGE,v as NOTIFY_SELECTED_PAGE,y as PAGES_CHANGED};
1
+ import"../_virtual/_rolldown/runtime.js";import{xmlBoolean as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{withSignals as n}from"./signals.js";import{GtkImage as r}from"./gtk-image.js";import{attachRowPressFeedback as i}from"./row-press.js";import{AdwImageButton as a}from"./adw-image-button.js";import{applyTabViewVisibility as o,createTabViewState as s,tabBarVisibility as c,tabCloseVisibilities as l,tabLabelText as u,tabViewNotifyPayload as d}from"./tab-view-state.js";import{GridLayout as f,ItemSpec as p,Label as m,StackLayout as h}from"@nativescript/core";import{tabIconState as g}from"@gjsify/adwaita-core";import{windowCloseSymbolic as _}from"@gjsify/adwaita-icons/ui";const v=`notify::selected-page`,y=`pages-changed`,b=`close-page`;var AdwTabView=class extends n(f){_state=s({onClosePage:e=>this._requestClose(e)});_bar;_contentArea;_chips=new Map;_autohide=!1;_defaultIcon=null;_generatedIds=0;closeHandler=null;constructor(e){super(),this.className=`adw-tab-view`,this.addColumn(new p(1,`star`)),this.addRow(new p(1,`auto`)),this.addRow(new p(1,`star`));let n=new h;n.orientation=`horizontal`,n.horizontalAlignment=`stretch`,n.className=`adw-tab-view-bar`,f.setRow(n,0),this.addChild(n),this._bar=n;let r=new f;r.addColumn(new p(1,`star`)),r.addRow(new p(1,`star`)),f.setRow(r,1),this.addChild(r),this._contentArea=r,this._state.subscribePages(e=>this._onPagesChange(e)),this._state.subscribe(e=>{this._applySelection();let t={eventName:v,object:this,...d(e)};this.notify(t)}),t(this,e)}get pages(){return this._state.pages}get nPages(){return this._state.nPages}get nPinnedPages(){return this._state.nPinnedPages}get selectedId(){return this._state.selectedId}get selectedIndex(){return this._state.selectedIndex}get selectedPage(){return this._state.selectedPage}set selectedPage(e){this._state.setSelectedPage(e)}isClosing(e){return this._state.isClosing(e)}set_selected_page(e){return this._state.setSelectedPage(e)}selectNthPage(e){return this._state.selectNthPage(e)}select_previous_page(){return this._state.selectPreviousPage()}select_next_page(){return this._state.selectNextPage()}selectFirstPage(){return this._state.selectFirstPage()}selectLastPage(){return this._state.selectLastPage()}cycleNextPage(){return this._state.cycleNextPage()}cyclePreviousPage(){return this._state.cyclePreviousPage()}addPage(e,t=null){return this._state.addPage(e,t)}insertPage(e,t){return this._state.insertPage(e,t)}prependPage(e){return this._state.prependPage(e)}appendPage(e){return this._state.appendPage(e)}insertPinnedPage(e,t){return this._state.insertPinnedPage(e,t)}prependPinnedPage(e){return this._state.prependPinnedPage(e)}appendPinnedPage(e){return this._state.appendPinnedPage(e)}setPagePinned(e,t){return this._state.setPagePinned(e,t)}closePage(e){return this._state.closePage(e)}closePageFinish(e,t){return this._state.closePageFinish(e,t)}closeOtherPages(e){this._state.closeOtherPages(e)}closePagesBefore(e){this._state.closePagesBefore(e)}closePagesAfter(e){this._state.closePagesAfter(e)}detachPage(e){return this._state.detachPage(e)}reorderPage(e,t){return this._state.reorderPage(e,t)}reorderBackward(e){return this._state.reorderBackward(e)}reorderForward(e){return this._state.reorderForward(e)}reorderFirst(e){return this._state.reorderFirst(e)}reorderLast(e){return this._state.reorderLast(e)}setPageTitle(e,t){return this._state.setPageTitle(e,t)}setPageIcon(e,t){return this._state.setPageIcon(e,t)}setPageLoading(e,t){return this._state.setPageLoading(e,t)}setPageNeedsAttention(e,t){return this._state.setPageNeedsAttention(e,t)}get diagnostics(){return this._state.diagnostics}get autohide(){return this._autohide}set autohide(t){let n=e(t,this.autohide);this._autohide=!!n,this._applyBarVisibility()}get defaultIcon(){return this._defaultIcon}set defaultIcon(e){this._defaultIcon=e;for(let e of this._state.pages)this._refreshChip(e.id)}setViews(e){for(let e of this._state.pages)this._state.detachPage(e.id);for(let t of e)this._state.appendPage({id:this._nextId(),title:t.title,icon:t.icon??null,content:t.content})}get views(){return this._state.pages.map(e=>({title:e.title,content:e.content,icon:e.icon??void 0}))}set views(e){this.setViews(Array.isArray(e)?e:[])}get tabs(){return this.views}set tabs(e){this.views=e}_onPagesChange(e){switch(e.kind){case`attached`:{let t=this._state.getPage(e.id);t&&this._insertChip(t,e.position);break}case`detached`:{let t=this._chips.get(e.id);t&&this._bar.removeChild(t.button),this._chips.delete(e.id);break}case`reordered`:case`pinned`:{let t=this._chips.get(e.id);t&&(this._bar.removeChild(t.button),this._bar.insertChild(t.button,e.position)),this._refreshChip(e.id);break}case`updated`:this._refreshChip(e.id);break}this._applyBarVisibility(),this._applySelection();let t={eventName:y,object:this,...e};this.notify(t)}_insertChip(e,t){let n=new h;n.orientation=`horizontal`,n.className=`adw-tab-view-tab`,n.verticalAlignment=`middle`;let o=new r;o.className=`${o.className} adw-tab-view-tab-icon`.trim(),o.verticalAlignment=`middle`,n.addChild(o);let s=new r;s.className=`${s.className} adw-tab-view-tab-icon`.trim(),s.verticalAlignment=`middle`,n.addChild(s);let c=new m;c.className=`adw-tab-view-tab-label`,c.verticalAlignment=`middle`,n.addChild(c);let l=new a;l.className=`${l.className} adw-tab-close`.trim(),l.iconName=_,l.pixelSize=12,l.verticalAlignment=`middle`,l.addEventListener(`tap`,()=>this._state.closePage(e.id)),n.addChild(l),i(n),n.addEventListener(`tap`,()=>this._state.setSelectedPage(e.id)),this._bar.insertChild(n,t),this._chips.set(e.id,{button:n,icon:o,indicator:s,label:c,close:l});let u=e.content;u&&(f.setColumn(u,0),f.setRow(u,0),this._contentArea.addChild(u)),this._refreshChip(e.id)}_refreshChip(e){let t=this._state.getPage(e),n=this._chips.get(e);if(!t||!n)return;n.label.text=u(t),n.label.visibility=t.pinned?`collapse`:`visible`;let r=g(t,this._defaultIcon);n.icon.iconName=r.icon??``,n.icon.visibility=r.iconVisible&&r.icon!==null?`visible`:`collapse`,n.indicator.iconName=t.indicatorIcon??``,n.indicator.visibility=r.indicatorVisible?`visible`:`collapse`}_applySelection(){o(this._state);let e=l(this._state),t=this._state.selectedId;this._state.pages.forEach((n,r)=>{let i=this._chips.get(n.id);i&&(i.button.className=n.id===t?`adw-tab-view-tab active`:`adw-tab-view-tab`,i.close.visibility=e[r])})}_applyBarVisibility(){this._bar.visibility=c(this._state,this._autohide)}_requestClose(e){let t={eventName:b,object:this,id:e.id,index:this._state.getPagePosition(e.id)};return this.notify(t),this.closeHandler?this.closeHandler(e):!e.pinned}_nextId(){return this._generatedIds+=1,`tab-${this._generatedIds}`}};export{AdwTabView,b as CLOSE_PAGE,v as NOTIFY_SELECTED_PAGE,y as PAGES_CHANGED};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{GTK_ALIGN as e,NS_HORIZONTAL_ALIGNMENT as t,NS_VERTICAL_ALIGNMENT as n,gtkAlignRefusal as r}from"./gtk-align.js";const i={horizontalAlignment:`horizontal`,verticalAlignment:`vertical`};function settableDoor(e,t){for(let n=e;n!==null;n=Object.getPrototypeOf(n)){let e=Object.getOwnPropertyDescriptor(n,t);if(e!==void 0)return e.set===void 0?e.get===void 0&&e.writable===!0?`data`:null:`accessor`}return null}function nsAlignment(i,a){let o=a===`horizontal`?t:n,s=null;if(typeof i==`number`){if(s=Object.keys(e).find(t=>e[t]===i)??null,s===null)throw TypeError(`${i} is not a Gtk.Align constant. The seven members are ${Object.keys(e).join(`, `)}, holding the values ${[...new Set(Object.values(e))].join(`, `)}.`)}else typeof i==`string`&&Object.hasOwn(e,i)&&(s=i);if(s===null)return i;let c=o[s];if(c!==void 0)return c;throw TypeError(`Gtk.Align '${s}' has no ${a} counterpart in NativeScript: ${r(s)} The ${a} alignments that do are ${Object.keys(o).join(`, `)}.`)}function applyConstructProps(e,t){if(t!=null)for(let[n,r]of Object.entries(t)){if(settableDoor(e,n)===null)throw TypeError(`${e.constructor.name} has no settable '${n}'. A construct-props bag goes through the declared setters, so a key nothing declares is refused here rather than left as a dead own-property that renders nothing — the silent drop \`xml-values.ts\` exists for one door over.`);if(r===void 0)continue;let t=i[n];e[n]=t===void 0?r:nsAlignment(r,t)}}export{applyConstructProps,nsAlignment};
1
+ import"../_virtual/_rolldown/runtime.js";import{GTK_ALIGN as e,NS_HORIZONTAL_ALIGNMENT as t,NS_VERTICAL_ALIGNMENT as n,gtkAlignRefusal as r}from"./gtk-align.js";import{iconSizeNickOf as i}from"./gtk-icon-size.js";const a={horizontalAlignment:`horizontal`,verticalAlignment:`vertical`},o={iconSize:!0};function settableDoor(e,t){for(let n=e;n!==null;n=Object.getPrototypeOf(n)){let e=Object.getOwnPropertyDescriptor(n,t);if(e!==void 0)return e.set===void 0?e.get===void 0&&e.writable===!0?`data`:null:`accessor`}return null}function nsAlignment(i,a){let o=a===`horizontal`?t:n,s=null;if(typeof i==`number`){if(s=Object.keys(e).find(t=>e[t]===i)??null,s===null)throw TypeError(`${i} is not a Gtk.Align constant. The seven members are ${Object.keys(e).join(`, `)}, holding the values ${[...new Set(Object.values(e))].join(`, `)}.`)}else typeof i==`string`&&Object.hasOwn(e,i)&&(s=i);if(s===null)return i;let c=o[s];if(c!==void 0)return c;throw TypeError(`Gtk.Align '${s}' has no ${a} counterpart in NativeScript: ${r(s)} The ${a} alignments that do are ${Object.keys(o).join(`, `)}.`)}function applyConstructProps(e,t){if(t!=null)for(let[n,r]of Object.entries(t)){if(settableDoor(e,n)===null)throw TypeError(`${e.constructor.name} has no settable '${n}'. A construct-props bag goes through the declared setters, so a key nothing declares is refused here rather than left as a dead own-property that renders nothing — the silent drop \`xml-values.ts\` exists for one door over.`);if(r===void 0)continue;let t=a[n];e[n]=t===void 0?Object.hasOwn(o,n)?i(r):r:nsAlignment(r,t)}}export{applyConstructProps,nsAlignment};
@@ -0,0 +1 @@
1
+ import"../_virtual/_rolldown/runtime.js";const e=[`inherit`,`normal`,`large`],t={inherit:16,normal:16,large:32},n=t.inherit,r=Object.freeze(Object.fromEntries(e.map((e,t)=>[e,t])));function isGtkIconSizeNick(t){return typeof t==`string`&&e.includes(t)}function iconSizeNickOf(t){if(typeof t!=`number`)return t;let n=e.find(e=>r[e]===t);if(n!==void 0)return n;throw TypeError(`${t} is not a Gtk.IconSize constant. The three members are ${e.join(`, `)}, holding the values ${e.map(e=>r[e]).join(`, `)}. For a size in DIPs use \`pixelSize\`, which is what \`Gtk.Image:pixel-size\` is.`)}function gtkIconSizeNick(t,n){if(isGtkIconSizeNick(t))return t;throw TypeError(`Gtk.IconSize: ${JSON.stringify(t)} is not a member — it takes one of ${e.join(`, `)} (staying at '${n}'). For a size in DIPs use \`pixelSize\`, which is what \`Gtk.Image:pixel-size\` is.`)}const i=-1;function storedPixelSize(e){return Number.isFinite(e)&&e>0?e:-1}function iconPixelSize(e,n){return Number.isFinite(n)&&n>0?n:t[e]}export{n as DEFAULT_ICON_PIXEL_SIZE,r as GTK_ICON_SIZE,e as GTK_ICON_SIZE_NICKS,t as GTK_ICON_SIZE_PIXELS,i as PIXEL_SIZE_UNSET,gtkIconSizeNick,iconPixelSize,iconSizeNickOf,isGtkIconSizeNick,storedPixelSize};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{applyConstructProps as t}from"./construct-props.js";import{withSignals as n}from"./signals.js";import{onAdwaitaColorSchemeChanged as r,themeIconColor as i}from"./color-scheme.js";import{DEFAULT_ICON_COLOR as a}from"./icon-path.js";import{resolveIconSource as o}from"./icon-theme.js";import{renderSymbolicIcon as s}from"./icons.js";import{Image as c}from"@nativescript/core";const l=16;var GtkImage=class extends n(c){_icon=``;_iconColor=i();_explicitColor=!1;_iconSize=16;_unsubScheme=null;constructor(e){super(),this.className=`adw-icon`,this.stretch=`aspectFit`,this.width=this._iconSize,this.height=this._iconSize,this.addEventListener(`loaded`,()=>{this._syncThemeColor(),this._unsubScheme??=r(()=>this._syncThemeColor())}),this.addEventListener(`unloaded`,()=>{this._unsubScheme?.(),this._unsubScheme=null}),t(this,e)}_syncThemeColor(){if(this._explicitColor)return;let e=i();e!==this._iconColor&&(this._iconColor=e,this._render())}_render(){let e=o(this._icon);if(!e)return;let t=s(e,{size:this._iconSize,color:this._iconColor});t&&(this.imageSource=t)}get iconName(){return this._icon}set iconName(e){this._icon=e??``,this._render()}get iconColor(){return this._iconColor}set iconColor(e){this._explicitColor=!0,this._iconColor=e||a,this._render()}get iconSize(){return this._iconSize}set iconSize(t){let n=e(t,this.iconSize);this._iconSize=Number.isFinite(n)&&n>0?n:16,this.width=this._iconSize,this.height=this._iconSize,this._render()}};export{l as DEFAULT_GTK_IMAGE_SIZE,GtkImage};
1
+ import"../_virtual/_rolldown/runtime.js";import{xmlNumber as e}from"./xml-values.js";import{DEFAULT_ICON_PIXEL_SIZE as t,gtkIconSizeNick as n,iconPixelSize as r,storedPixelSize as i}from"./gtk-icon-size.js";import{applyConstructProps as a}from"./construct-props.js";import{withSignals as o}from"./signals.js";import{onAdwaitaColorSchemeChanged as s,themeIconColor as c}from"./color-scheme.js";import{DEFAULT_ICON_COLOR as l}from"./icon-path.js";import{resolveIconSource as u}from"./icon-theme.js";import{renderSymbolicIcon as d}from"./icons.js";import{Image as f}from"@nativescript/core";const p=t;var GtkImage=class extends o(f){_icon=``;_iconColor=c();_explicitColor=!1;_iconSize=`inherit`;_pixelSize=-1;_unsubScheme=null;constructor(e){super(),this.className=`adw-icon`,this.stretch=`aspectFit`,this._applySize(),this.addEventListener(`loaded`,()=>{this._syncThemeColor(),this._unsubScheme??=s(()=>this._syncThemeColor())}),this.addEventListener(`unloaded`,()=>{this._unsubScheme?.(),this._unsubScheme=null}),a(this,e)}_syncThemeColor(){if(this._explicitColor)return;let e=c();e!==this._iconColor&&(this._iconColor=e,this._render())}get _renderedSize(){return r(this._iconSize,this._pixelSize)}_applySize(){let e=this._renderedSize;this.width=e,this.height=e,this._render()}_render(){let e=u(this._icon);if(!e)return;let t=d(e,{size:this._renderedSize,color:this._iconColor});t&&(this.imageSource=t)}get iconName(){return this._icon}set iconName(e){this._icon=e??``,this._render()}get iconColor(){return this._iconColor}set iconColor(e){this._explicitColor=!0,this._iconColor=e||l,this._render()}get iconSize(){return this._iconSize}set iconSize(e){this._iconSize=n(e,this._iconSize),this._applySize()}get pixelSize(){return this._pixelSize}set pixelSize(t){this._pixelSize=i(e(t,this._pixelSize)),this._applySize()}};export{p as DEFAULT_GTK_IMAGE_SIZE,GtkImage};
@@ -1 +1 @@
1
- import"../_virtual/_rolldown/runtime.js";import{GTK_ALIGN as e}from"./gtk-align.js";import{applyConstructProps as t,nsAlignment as ee}from"./construct-props.js";import{AdwPreferencesPage as n}from"./adw-preferences-page.js";import{AdwPreferencesGroup as r}from"./adw-preferences-group.js";import{ACTIVATED as te,AdwActionRow as i}from"./adw-action-row.js";import{AdwSwitchRow as a,NOTIFY_ACTIVE as ne}from"./adw-switch-row.js";import{adwaitaColorScheme as re,isThemeIconColor as ie,onAdwaitaColorSchemeChanged as ae,setAdwaitaColorScheme as oe,themeIconColor as se,toggleAdwaitaColorScheme as ce}from"./color-scheme.js";import{ADWAITA_ICON_GRID as le,DEFAULT_ICON_COLOR as ue,DEFAULT_ICON_COLOR_DARK as de,extractIconPaths as fe,extractPathData as pe}from"./icon-path.js";import{ICON_FALLBACK_NAME as me,compiledIconNames as he,iconValueKind as ge,isIconAvailable as _e,registerIcon as ve,registeredIconNames as ye,resolveIconSource as be,unregisterIcon as xe}from"./icon-theme.js";import{renderSymbolicIcon as Se}from"./icons.js";import{DEFAULT_GTK_IMAGE_SIZE as Ce,GtkImage as o}from"./gtk-image.js";import{attachRowPressFeedback as we}from"./row-press.js";import{AdwImageButton as s,DEFAULT_ICON_BUTTON_ICON_SIZE as Te}from"./adw-image-button.js";import{AdwEntryRow as c,NOTIFY_TEXT as Ee}from"./adw-entry-row.js";import{AdwPasswordEntryRow as l}from"./adw-password-entry-row.js";import{ACTIVATE as De,GtkEntry as u,NOTIFY_TEXT as Oe}from"./gtk-entry.js";import{AdwComboRow as d,ComboState as ke,NOTIFY_SELECTED as Ae}from"./adw-combo-row.js";import{GtkDropDown as f,NOTIFY_SELECTED as je}from"./gtk-drop-down.js";import{AdwSpinRow as p,NOTIFY_VALUE as Me,SpinState as Ne}from"./adw-spin-row.js";import{AdwSliderRow as m,NOTIFY_SLIDER_VALUE as Pe}from"./adw-slider-row.js";import{AdwExpanderRow as h,ExpanderState as Fe,NOTIFY_EXPANDED as g}from"./adw-expander-row.js";import{buttonSlotAfterWrite as _,buttonSlotDetaches as v}from"./button-slot.js";import{labelDisplayText as Ie,labelMarkupIsUnparseable as Le}from"./label-text.js";import{GTK_BUTTON_CLICKED as Re,GTK_BUTTON_LABEL_CLASS as ze,GtkButton as y}from"./gtk-button.js";import{DEFAULT_BOX_SPACING as Be,boxChildMargin as Ve,boxSpacingChanges as He,normalizeBoxSpacing as Ue}from"./box-layout.js";import{GtkBox as b}from"./gtk-box.js";import{GtkLabel as x}from"./gtk-label.js";import{MENU_CANCEL_LABEL as We,menuSheetActions as Ge,menuSheetRows as Ke,presentMenuSheet as qe,resolveMenuChoice as Je}from"./menu-sheet.js";import{GtkMenuButton as S,MENU_ITEM_ACTIVATED as Ye}from"./gtk-menu-button.js";import{DEFAULT_CLAMP_MAX_SIZE as Xe,DEFAULT_SPINNER_SIZE as Ze}from"./chrome.js";import{AdwBanner as C,BUTTON_CLICKED as Qe}from"./adw-banner.js";import{avatarInitials as $e}from"./avatar-color.js";import{AVATAR_DEFAULT_ICON as et}from"./avatar-view.js";import{AdwAvatar as w,DEFAULT_AVATAR_SIZE as tt}from"./adw-avatar.js";import{AdwWindowTitle as T}from"./adw-window-title.js";import{AdwClamp as E}from"./adw-clamp.js";import{AdwHeaderBar as D}from"./adw-header-bar.js";import{AdwToolbarView as O}from"./adw-toolbar-view.js";import{AdwWrapBox as k}from"./adw-wrap-box.js";import{DATA_GRID_HEADER_CELL_CLASS as nt,DATA_GRID_HEADER_ROW_CLASS as rt,DATA_GRID_SECTION_CELL_CLASS as it,dataGridCellClass as at,dataGridItemSpec as ot,dataGridRowClass as st,dataGridShapeKey as ct,dataGridTracksKey as lt,parseDataGridWidth as ut}from"./data-grid-model.js";import{AdwDataGrid as A,ROW_ACTIVATED as dt}from"./adw-data-grid.js";import{AdwSpinner as j}from"./adw-spinner.js";import{AdwStatusPage as M}from"./adw-status-page.js";import{AdwButtonRow as N}from"./adw-button-row.js";import{AdwButtonContent as P}from"./adw-button-content.js";import{AdwSplitButton as F,CLICKED as ft,MENU_TAPPED as pt}from"./adw-split-button.js";import{AdwToggleGroup as I,NOTIFY_SELECTED as mt,ToggleGroupState as L}from"./adw-toggle-group.js";import{ADWAITA_NS_ACCENT_RULES as ht,adwaitaNsAccentColor as gt,adwaitaNsAccentCss as _t}from"./accent-theme.js";import{applyAdwaitaNsAccent as vt,clearAdwaitaNsAccent as yt}from"./adw-accent.js";import{SHORTCUT_LABEL_CAP_TEXT_CLASS as bt,SHORTCUT_LABEL_CLASS as xt,SHORTCUT_LABEL_DIMMED_CLASS as St,SHORTCUT_LABEL_DISABLED_CLASS as Ct,SHORTCUT_LABEL_KEYCAP_CLASS as wt,SHORTCUT_LABEL_KEYS_CLASS as Tt,SHORTCUT_LABEL_SIDE_CLASS as Et,SHORTCUT_LABEL_SPACED_CLASS as Dt,shortcutLabelDirection as Ot,shortcutLabelPlatform as kt,shortcutLabelRenderPlan as At}from"./shortcut-label.js";import{AdwShortcutLabel as R}from"./adw-shortcut-label.js";import{AdwViewStack as z,NOTIFY_VISIBLE_CHILD as jt}from"./adw-view-stack.js";import{AdwViewSwitcherBase as Mt,NOTIFY_SELECTED as Nt}from"./view-switcher-base.js";import{AdwViewSwitcher as B}from"./adw-view-switcher.js";import{AdwViewSwitcherBar as V}from"./adw-view-switcher-bar.js";import{AdwInlineViewSwitcher as H}from"./adw-inline-view-switcher.js";import{applyTabViewVisibility as Pt,createTabViewState as Ft,tabBarVisibility as It,tabCloseVisibilities as Lt,tabLabelText as Rt,tabPageVisibilities as zt,tabTooltipText as Bt,tabViewNotifyPayload as Vt}from"./tab-view-state.js";import{AdwTabView as U,CLOSE_PAGE as Ht,NOTIFY_SELECTED_PAGE as Ut,PAGES_CHANGED as Wt}from"./adw-tab-view.js";import{CarouselScrollSync as Gt,DEFAULT_CAROUSEL_PAGE_WIDTH as Kt,applyCarouselDots as qt,carouselDotClasses as Jt,carouselNotifyPayload as Yt,carouselPositionAtOffset as Xt,carouselScrollOffset as Zt,createCarouselState as Qt,normalizeCarouselPageWidth as $t}from"./carousel-state.js";import{AdwCarousel as W,NOTIFY_N_PAGES as en,NOTIFY_POSITION as tn,PAGE_CHANGED as nn}from"./adw-carousel.js";import{NOTIFY_VISIBLE_PAGE as rn}from"./navigation-stack.js";import{AdwNavigationView as G}from"./adw-navigation-view.js";import{NsNavigationSplitViewState as an,NsOverlaySplitViewState as on,splitViewColumns as sn}from"./split-view-state.js";import{AdwSplitViewBase as cn,NOTIFY_SHOW_SIDEBAR as ln}from"./split-view-base.js";import{AdwNavigationSplitView as K}from"./adw-navigation-split-view.js";import{AdwOverlaySplitView as q}from"./adw-overlay-split-view.js";import{AdwSidebar as J,NOTIFY_SELECTED as un}from"./adw-sidebar.js";import{CLOSE_ATTEMPT as dn,NOTIFY_OPEN as fn,SHEET_CLOSE as pn}from"./bottom-sheet-state.js";import{AdwBottomSheet as Y}from"./adw-bottom-sheet.js";import{AdwToast as mn,AdwToastOverlay as X,AdwToastQueue as hn,DEFAULT_TOAST_TIMEOUT as gn,TOAST_BUTTON_CLICKED as _n}from"./adw-toast-overlay.js";import{AdwAlertDialog as vn,AdwAlertResponses as yn,NOTIFY_RESPONSE as bn}from"./adw-alert-dialog.js";import{AdwAboutDialog as Z,CLOSED as xn}from"./adw-about-dialog.js";import{AdwPreferencesDialog as Q,CLOSED as Sn}from"./adw-preferences-dialog.js";import{AdwBreakpoint as Cn,addBreakpoints as wn,evaluateBreakpointCondition as Tn,parseBreakpointCondition as En}from"./breakpoint.js";const Dn={AdwPreferencesPage:n,AdwPreferencesGroup:r,AdwActionRow:i,AdwSwitchRow:a,AdwEntryRow:c,AdwPasswordEntryRow:l,GtkEntry:u,AdwComboRow:d,GtkDropDown:f,AdwSpinRow:p,AdwSliderRow:m,AdwExpanderRow:h,GtkButton:y,GtkBox:b,GtkLabel:x,AdwImageButton:s,GtkMenuButton:S,GtkImage:o,AdwBanner:C,AdwAvatar:w,AdwWindowTitle:T,AdwClamp:E,AdwHeaderBar:D,AdwToolbarView:O,AdwWrapBox:k,AdwDataGrid:A,AdwSpinner:j,AdwStatusPage:M,AdwButtonRow:N,AdwButtonContent:P,AdwSplitButton:F,AdwToggleGroup:I,AdwShortcutLabel:R,AdwViewStack:z,AdwViewSwitcher:B,AdwViewSwitcherBar:V,AdwInlineViewSwitcher:H,AdwTabView:U,AdwCarousel:W,AdwNavigationView:G,AdwNavigationSplitView:K,AdwOverlaySplitView:q,AdwSidebar:J,AdwBottomSheet:Y,AdwToastOverlay:X,AdwAboutDialog:Z,AdwPreferencesDialog:Q};let $=!1;function registerAdwaitaElements(){if(!$&&typeof registerElement==`function`){for(let[e,t]of Object.entries(Dn))registerElement(e,()=>t);$=!0}}export{xn as ABOUT_CLOSED,te as ACTIVATED,le as ADWAITA_ICON_GRID,ht as ADWAITA_NS_ACCENT_RULES,et as AVATAR_DEFAULT_ICON,Z as AdwAboutDialog,i as AdwActionRow,vn as AdwAlertDialog,yn as AdwAlertResponses,w as AdwAvatar,C as AdwBanner,Y as AdwBottomSheet,Cn as AdwBreakpoint,P as AdwButtonContent,N as AdwButtonRow,W as AdwCarousel,E as AdwClamp,d as AdwComboRow,A as AdwDataGrid,c as AdwEntryRow,h as AdwExpanderRow,D as AdwHeaderBar,s as AdwImageButton,H as AdwInlineViewSwitcher,K as AdwNavigationSplitView,G as AdwNavigationView,q as AdwOverlaySplitView,l as AdwPasswordEntryRow,Q as AdwPreferencesDialog,r as AdwPreferencesGroup,n as AdwPreferencesPage,R as AdwShortcutLabel,J as AdwSidebar,m as AdwSliderRow,p as AdwSpinRow,j as AdwSpinner,F as AdwSplitButton,cn as AdwSplitViewBase,M as AdwStatusPage,a as AdwSwitchRow,U as AdwTabView,mn as AdwToast,X as AdwToastOverlay,hn as AdwToastQueue,I as AdwToggleGroup,O as AdwToolbarView,z as AdwViewStack,B as AdwViewSwitcher,V as AdwViewSwitcherBar,Mt as AdwViewSwitcherBase,T as AdwWindowTitle,k as AdwWrapBox,Qe as BUTTON_CLICKED,ft as CLICKED,dn as CLOSE_ATTEMPT,Ht as CLOSE_PAGE,Gt as CarouselScrollSync,ke as ComboState,nt as DATA_GRID_HEADER_CELL_CLASS,rt as DATA_GRID_HEADER_ROW_CLASS,it as DATA_GRID_SECTION_CELL_CLASS,tt as DEFAULT_AVATAR_SIZE,Be as DEFAULT_BOX_SPACING,Kt as DEFAULT_CAROUSEL_PAGE_WIDTH,Xe as DEFAULT_CLAMP_MAX_SIZE,Ce as DEFAULT_GTK_IMAGE_SIZE,Te as DEFAULT_ICON_BUTTON_ICON_SIZE,ue as DEFAULT_ICON_COLOR,de as DEFAULT_ICON_COLOR_DARK,Ze as DEFAULT_SPINNER_SIZE,gn as DEFAULT_TOAST_TIMEOUT,De as ENTRY_ACTIVATE,Fe as ExpanderState,e as GTK_ALIGN,Re as GTK_BUTTON_CLICKED,ze as GTK_BUTTON_LABEL_CLASS,b as GtkBox,y as GtkButton,f as GtkDropDown,u as GtkEntry,o as GtkImage,x as GtkLabel,S as GtkMenuButton,me as ICON_FALLBACK_NAME,We as MENU_CANCEL_LABEL,Ye as MENU_ITEM_ACTIVATED,pt as MENU_TAPPED,ne as NOTIFY_ACTIVE,je as NOTIFY_DROP_DOWN_SELECTED,Oe as NOTIFY_ENTRY_TEXT,g as NOTIFY_EXPANDED,en as NOTIFY_N_PAGES,fn as NOTIFY_OPEN,tn as NOTIFY_POSITION,bn as NOTIFY_RESPONSE,Ae as NOTIFY_SELECTED,Ut as NOTIFY_SELECTED_PAGE,ln as NOTIFY_SHOW_SIDEBAR,un as NOTIFY_SIDEBAR_SELECTED,Pe as NOTIFY_SLIDER_VALUE,Ee as NOTIFY_TEXT,mt as NOTIFY_TOGGLE_SELECTED,Me as NOTIFY_VALUE,Nt as NOTIFY_VIEW_SELECTED,jt as NOTIFY_VISIBLE_CHILD,rn as NOTIFY_VISIBLE_PAGE,an as NsNavigationSplitViewState,on as NsOverlaySplitViewState,Wt as PAGES_CHANGED,nn as PAGE_CHANGED,Sn as PREFERENCES_CLOSED,dt as ROW_ACTIVATED,pn as SHEET_CLOSE,bt as SHORTCUT_LABEL_CAP_TEXT_CLASS,xt as SHORTCUT_LABEL_CLASS,St as SHORTCUT_LABEL_DIMMED_CLASS,Ct as SHORTCUT_LABEL_DISABLED_CLASS,wt as SHORTCUT_LABEL_KEYCAP_CLASS,Tt as SHORTCUT_LABEL_KEYS_CLASS,Et as SHORTCUT_LABEL_SIDE_CLASS,Dt as SHORTCUT_LABEL_SPACED_CLASS,Ne as SpinState,_n as TOAST_BUTTON_CLICKED,L as ToggleGroupState,wn as addBreakpoints,re as adwaitaColorScheme,gt as adwaitaNsAccentColor,_t as adwaitaNsAccentCss,vt as applyAdwaitaNsAccent,qt as applyCarouselDots,t as applyConstructProps,Pt as applyTabViewVisibility,we as attachRowPressFeedback,$e as avatarInitials,Ve as boxChildMargin,He as boxSpacingChanges,_ as buttonSlotAfterWrite,v as buttonSlotDetaches,Jt as carouselDotClasses,Yt as carouselNotifyPayload,Xt as carouselPositionAtOffset,Zt as carouselScrollOffset,yt as clearAdwaitaNsAccent,he as compiledIconNames,Qt as createCarouselState,Ft as createTabViewState,at as dataGridCellClass,ot as dataGridItemSpec,st as dataGridRowClass,ct as dataGridShapeKey,lt as dataGridTracksKey,Tn as evaluateBreakpointCondition,fe as extractIconPaths,pe as extractPathData,ge as iconValueKind,_e as isIconAvailable,ie as isThemeIconColor,Ie as labelDisplayText,Le as labelMarkupIsUnparseable,Ge as menuSheetActions,Ke as menuSheetRows,Ue as normalizeBoxSpacing,$t as normalizeCarouselPageWidth,ee as nsAlignment,ae as onAdwaitaColorSchemeChanged,En as parseBreakpointCondition,ut as parseDataGridWidth,qe as presentMenuSheet,registerAdwaitaElements,ve as registerIcon,ye as registeredIconNames,Se as renderSymbolicIcon,be as resolveIconSource,Je as resolveMenuChoice,oe as setAdwaitaColorScheme,Ot as shortcutLabelDirection,kt as shortcutLabelPlatform,At as shortcutLabelRenderPlan,sn as splitViewColumns,It as tabBarVisibility,Lt as tabCloseVisibilities,Rt as tabLabelText,zt as tabPageVisibilities,Bt as tabTooltipText,Vt as tabViewNotifyPayload,se as themeIconColor,ce as toggleAdwaitaColorScheme,xe as unregisterIcon};
1
+ import"../_virtual/_rolldown/runtime.js";import{GTK_ALIGN as e}from"./gtk-align.js";import{DEFAULT_ICON_PIXEL_SIZE as t,GTK_ICON_SIZE_NICKS as ee,GTK_ICON_SIZE_PIXELS as te,PIXEL_SIZE_UNSET as ne,isGtkIconSizeNick as re}from"./gtk-icon-size.js";import{applyConstructProps as ie,nsAlignment as ae}from"./construct-props.js";import{AdwPreferencesPage as n}from"./adw-preferences-page.js";import{AdwPreferencesGroup as r}from"./adw-preferences-group.js";import{ACTIVATED as oe,AdwActionRow as i}from"./adw-action-row.js";import{AdwSwitchRow as a,NOTIFY_ACTIVE as se}from"./adw-switch-row.js";import{adwaitaColorScheme as o,isThemeIconColor as ce,onAdwaitaColorSchemeChanged as le,setAdwaitaColorScheme as ue,themeIconColor as de,toggleAdwaitaColorScheme as fe}from"./color-scheme.js";import{ADWAITA_ICON_GRID as pe,DEFAULT_ICON_COLOR as me,DEFAULT_ICON_COLOR_DARK as he,extractIconPaths as ge,extractPathData as _e}from"./icon-path.js";import{ICON_FALLBACK_NAME as ve,compiledIconNames as ye,iconValueKind as be,isIconAvailable as xe,registerIcon as Se,registeredIconNames as Ce,resolveIconSource as we,unregisterIcon as Te}from"./icon-theme.js";import{renderSymbolicIcon as Ee}from"./icons.js";import{DEFAULT_GTK_IMAGE_SIZE as De,GtkImage as s}from"./gtk-image.js";import{attachRowPressFeedback as Oe}from"./row-press.js";import{AdwImageButton as c,DEFAULT_ICON_BUTTON_ICON_SIZE as ke}from"./adw-image-button.js";import{AdwEntryRow as l,NOTIFY_TEXT as Ae}from"./adw-entry-row.js";import{AdwPasswordEntryRow as u}from"./adw-password-entry-row.js";import{ACTIVATE as je,GtkEntry as d,NOTIFY_TEXT as Me}from"./gtk-entry.js";import{AdwComboRow as f,ComboState as Ne,NOTIFY_SELECTED as Pe}from"./adw-combo-row.js";import{GtkDropDown as p,NOTIFY_SELECTED as Fe}from"./gtk-drop-down.js";import{AdwSpinRow as m,NOTIFY_VALUE as Ie,SpinState as h}from"./adw-spin-row.js";import{AdwSliderRow as g,NOTIFY_SLIDER_VALUE as _}from"./adw-slider-row.js";import{AdwExpanderRow as v,ExpanderState as Le,NOTIFY_EXPANDED as Re}from"./adw-expander-row.js";import{buttonSlotAfterWrite as ze,buttonSlotDetaches as Be}from"./button-slot.js";import{labelDisplayText as Ve,labelMarkupIsUnparseable as He}from"./label-text.js";import{GTK_BUTTON_CLICKED as Ue,GTK_BUTTON_LABEL_CLASS as We,GtkButton as y}from"./gtk-button.js";import{DEFAULT_BOX_SPACING as Ge,boxChildMargin as Ke,boxSpacingChanges as qe,normalizeBoxSpacing as Je}from"./box-layout.js";import{GtkBox as b}from"./gtk-box.js";import{GtkLabel as x}from"./gtk-label.js";import{MENU_CANCEL_LABEL as Ye,menuSheetActions as Xe,menuSheetRows as Ze,presentMenuSheet as Qe,resolveMenuChoice as $e}from"./menu-sheet.js";import{GtkMenuButton as S,MENU_ITEM_ACTIVATED as et}from"./gtk-menu-button.js";import{DEFAULT_CLAMP_MAX_SIZE as tt,DEFAULT_SPINNER_SIZE as nt}from"./chrome.js";import{AdwBanner as C,BUTTON_CLICKED as rt}from"./adw-banner.js";import{avatarInitials as it}from"./avatar-color.js";import{AVATAR_DEFAULT_ICON as at}from"./avatar-view.js";import{AdwAvatar as w,DEFAULT_AVATAR_SIZE as ot}from"./adw-avatar.js";import{AdwWindowTitle as T}from"./adw-window-title.js";import{AdwClamp as E}from"./adw-clamp.js";import{AdwHeaderBar as D}from"./adw-header-bar.js";import{AdwToolbarView as O}from"./adw-toolbar-view.js";import{AdwWrapBox as k}from"./adw-wrap-box.js";import{DATA_GRID_HEADER_CELL_CLASS as st,DATA_GRID_HEADER_ROW_CLASS as ct,DATA_GRID_SECTION_CELL_CLASS as lt,dataGridCellClass as ut,dataGridItemSpec as dt,dataGridRowClass as ft,dataGridShapeKey as pt,dataGridTracksKey as mt,parseDataGridWidth as ht}from"./data-grid-model.js";import{AdwDataGrid as A,ROW_ACTIVATED as gt}from"./adw-data-grid.js";import{AdwSpinner as j}from"./adw-spinner.js";import{AdwStatusPage as M}from"./adw-status-page.js";import{AdwButtonRow as N}from"./adw-button-row.js";import{AdwButtonContent as P}from"./adw-button-content.js";import{AdwSplitButton as F,CLICKED as _t,MENU_TAPPED as vt}from"./adw-split-button.js";import{AdwToggleGroup as I,NOTIFY_SELECTED as yt,ToggleGroupState as bt}from"./adw-toggle-group.js";import{ADWAITA_NS_ACCENT_RULES as xt,adwaitaNsAccentColor as St,adwaitaNsAccentCss as Ct}from"./accent-theme.js";import{applyAdwaitaNsAccent as wt,clearAdwaitaNsAccent as Tt}from"./adw-accent.js";import{SHORTCUT_LABEL_CAP_TEXT_CLASS as Et,SHORTCUT_LABEL_CLASS as Dt,SHORTCUT_LABEL_DIMMED_CLASS as Ot,SHORTCUT_LABEL_DISABLED_CLASS as kt,SHORTCUT_LABEL_KEYCAP_CLASS as At,SHORTCUT_LABEL_KEYS_CLASS as jt,SHORTCUT_LABEL_SIDE_CLASS as Mt,SHORTCUT_LABEL_SPACED_CLASS as Nt,shortcutLabelDirection as Pt,shortcutLabelPlatform as Ft,shortcutLabelRenderPlan as It}from"./shortcut-label.js";import{AdwShortcutLabel as L}from"./adw-shortcut-label.js";import{AdwViewStack as R,NOTIFY_VISIBLE_CHILD as Lt}from"./adw-view-stack.js";import{AdwViewSwitcherBase as Rt,NOTIFY_SELECTED as zt}from"./view-switcher-base.js";import{AdwViewSwitcher as z}from"./adw-view-switcher.js";import{AdwViewSwitcherBar as B}from"./adw-view-switcher-bar.js";import{AdwInlineViewSwitcher as V}from"./adw-inline-view-switcher.js";import{applyTabViewVisibility as Bt,createTabViewState as Vt,tabBarVisibility as Ht,tabCloseVisibilities as Ut,tabLabelText as Wt,tabPageVisibilities as Gt,tabTooltipText as Kt,tabViewNotifyPayload as qt}from"./tab-view-state.js";import{AdwTabView as H,CLOSE_PAGE as Jt,NOTIFY_SELECTED_PAGE as Yt,PAGES_CHANGED as Xt}from"./adw-tab-view.js";import{CarouselScrollSync as Zt,DEFAULT_CAROUSEL_PAGE_WIDTH as Qt,applyCarouselDots as $t,carouselDotClasses as en,carouselNotifyPayload as tn,carouselPositionAtOffset as nn,carouselScrollOffset as rn,createCarouselState as an,normalizeCarouselPageWidth as on}from"./carousel-state.js";import{AdwCarousel as U,NOTIFY_N_PAGES as sn,NOTIFY_POSITION as cn,PAGE_CHANGED as ln}from"./adw-carousel.js";import{NOTIFY_VISIBLE_PAGE as un}from"./navigation-stack.js";import{AdwNavigationView as W}from"./adw-navigation-view.js";import{NsNavigationSplitViewState as dn,NsOverlaySplitViewState as fn,splitViewColumns as pn}from"./split-view-state.js";import{AdwSplitViewBase as mn,NOTIFY_SHOW_SIDEBAR as hn}from"./split-view-base.js";import{AdwNavigationSplitView as G}from"./adw-navigation-split-view.js";import{AdwOverlaySplitView as K}from"./adw-overlay-split-view.js";import{AdwSidebar as q,NOTIFY_SELECTED as gn}from"./adw-sidebar.js";import{CLOSE_ATTEMPT as _n,NOTIFY_OPEN as vn,SHEET_CLOSE as yn}from"./bottom-sheet-state.js";import{AdwBottomSheet as J}from"./adw-bottom-sheet.js";import{AdwToast as bn,AdwToastOverlay as Y,AdwToastQueue as xn,DEFAULT_TOAST_TIMEOUT as Sn,TOAST_BUTTON_CLICKED as Cn}from"./adw-toast-overlay.js";import{AdwAlertDialog as wn,AdwAlertResponses as Tn,NOTIFY_RESPONSE as En}from"./adw-alert-dialog.js";import{AdwAboutDialog as X,CLOSED as Dn}from"./adw-about-dialog.js";import{AdwPreferencesDialog as Z,CLOSED as On}from"./adw-preferences-dialog.js";import{AdwBreakpoint as kn,addBreakpoints as Q,evaluateBreakpointCondition as An,parseBreakpointCondition as jn}from"./breakpoint.js";const Mn={AdwPreferencesPage:n,AdwPreferencesGroup:r,AdwActionRow:i,AdwSwitchRow:a,AdwEntryRow:l,AdwPasswordEntryRow:u,GtkEntry:d,AdwComboRow:f,GtkDropDown:p,AdwSpinRow:m,AdwSliderRow:g,AdwExpanderRow:v,GtkButton:y,GtkBox:b,GtkLabel:x,AdwImageButton:c,GtkMenuButton:S,GtkImage:s,AdwBanner:C,AdwAvatar:w,AdwWindowTitle:T,AdwClamp:E,AdwHeaderBar:D,AdwToolbarView:O,AdwWrapBox:k,AdwDataGrid:A,AdwSpinner:j,AdwStatusPage:M,AdwButtonRow:N,AdwButtonContent:P,AdwSplitButton:F,AdwToggleGroup:I,AdwShortcutLabel:L,AdwViewStack:R,AdwViewSwitcher:z,AdwViewSwitcherBar:B,AdwInlineViewSwitcher:V,AdwTabView:H,AdwCarousel:U,AdwNavigationView:W,AdwNavigationSplitView:G,AdwOverlaySplitView:K,AdwSidebar:q,AdwBottomSheet:J,AdwToastOverlay:Y,AdwAboutDialog:X,AdwPreferencesDialog:Z};let $=!1;function registerAdwaitaElements(){if(!$&&typeof registerElement==`function`){for(let[e,t]of Object.entries(Mn))registerElement(e,()=>t);$=!0}}export{Dn as ABOUT_CLOSED,oe as ACTIVATED,pe as ADWAITA_ICON_GRID,xt as ADWAITA_NS_ACCENT_RULES,at as AVATAR_DEFAULT_ICON,X as AdwAboutDialog,i as AdwActionRow,wn as AdwAlertDialog,Tn as AdwAlertResponses,w as AdwAvatar,C as AdwBanner,J as AdwBottomSheet,kn as AdwBreakpoint,P as AdwButtonContent,N as AdwButtonRow,U as AdwCarousel,E as AdwClamp,f as AdwComboRow,A as AdwDataGrid,l as AdwEntryRow,v as AdwExpanderRow,D as AdwHeaderBar,c as AdwImageButton,V as AdwInlineViewSwitcher,G as AdwNavigationSplitView,W as AdwNavigationView,K as AdwOverlaySplitView,u as AdwPasswordEntryRow,Z as AdwPreferencesDialog,r as AdwPreferencesGroup,n as AdwPreferencesPage,L as AdwShortcutLabel,q as AdwSidebar,g as AdwSliderRow,m as AdwSpinRow,j as AdwSpinner,F as AdwSplitButton,mn as AdwSplitViewBase,M as AdwStatusPage,a as AdwSwitchRow,H as AdwTabView,bn as AdwToast,Y as AdwToastOverlay,xn as AdwToastQueue,I as AdwToggleGroup,O as AdwToolbarView,R as AdwViewStack,z as AdwViewSwitcher,B as AdwViewSwitcherBar,Rt as AdwViewSwitcherBase,T as AdwWindowTitle,k as AdwWrapBox,rt as BUTTON_CLICKED,_t as CLICKED,_n as CLOSE_ATTEMPT,Jt as CLOSE_PAGE,Zt as CarouselScrollSync,Ne as ComboState,st as DATA_GRID_HEADER_CELL_CLASS,ct as DATA_GRID_HEADER_ROW_CLASS,lt as DATA_GRID_SECTION_CELL_CLASS,ot as DEFAULT_AVATAR_SIZE,Ge as DEFAULT_BOX_SPACING,Qt as DEFAULT_CAROUSEL_PAGE_WIDTH,tt as DEFAULT_CLAMP_MAX_SIZE,De as DEFAULT_GTK_IMAGE_SIZE,ke as DEFAULT_ICON_BUTTON_ICON_SIZE,me as DEFAULT_ICON_COLOR,he as DEFAULT_ICON_COLOR_DARK,t as DEFAULT_ICON_PIXEL_SIZE,nt as DEFAULT_SPINNER_SIZE,Sn as DEFAULT_TOAST_TIMEOUT,je as ENTRY_ACTIVATE,Le as ExpanderState,e as GTK_ALIGN,Ue as GTK_BUTTON_CLICKED,We as GTK_BUTTON_LABEL_CLASS,ee as GTK_ICON_SIZE_NICKS,te as GTK_ICON_SIZE_PIXELS,b as GtkBox,y as GtkButton,p as GtkDropDown,d as GtkEntry,s as GtkImage,x as GtkLabel,S as GtkMenuButton,ve as ICON_FALLBACK_NAME,Ye as MENU_CANCEL_LABEL,et as MENU_ITEM_ACTIVATED,vt as MENU_TAPPED,se as NOTIFY_ACTIVE,Fe as NOTIFY_DROP_DOWN_SELECTED,Me as NOTIFY_ENTRY_TEXT,Re as NOTIFY_EXPANDED,sn as NOTIFY_N_PAGES,vn as NOTIFY_OPEN,cn as NOTIFY_POSITION,En as NOTIFY_RESPONSE,Pe as NOTIFY_SELECTED,Yt as NOTIFY_SELECTED_PAGE,hn as NOTIFY_SHOW_SIDEBAR,gn as NOTIFY_SIDEBAR_SELECTED,_ as NOTIFY_SLIDER_VALUE,Ae as NOTIFY_TEXT,yt as NOTIFY_TOGGLE_SELECTED,Ie as NOTIFY_VALUE,zt as NOTIFY_VIEW_SELECTED,Lt as NOTIFY_VISIBLE_CHILD,un as NOTIFY_VISIBLE_PAGE,dn as NsNavigationSplitViewState,fn as NsOverlaySplitViewState,Xt as PAGES_CHANGED,ln as PAGE_CHANGED,ne as PIXEL_SIZE_UNSET,On as PREFERENCES_CLOSED,gt as ROW_ACTIVATED,yn as SHEET_CLOSE,Et as SHORTCUT_LABEL_CAP_TEXT_CLASS,Dt as SHORTCUT_LABEL_CLASS,Ot as SHORTCUT_LABEL_DIMMED_CLASS,kt as SHORTCUT_LABEL_DISABLED_CLASS,At as SHORTCUT_LABEL_KEYCAP_CLASS,jt as SHORTCUT_LABEL_KEYS_CLASS,Mt as SHORTCUT_LABEL_SIDE_CLASS,Nt as SHORTCUT_LABEL_SPACED_CLASS,h as SpinState,Cn as TOAST_BUTTON_CLICKED,bt as ToggleGroupState,Q as addBreakpoints,o as adwaitaColorScheme,St as adwaitaNsAccentColor,Ct as adwaitaNsAccentCss,wt as applyAdwaitaNsAccent,$t as applyCarouselDots,ie as applyConstructProps,Bt as applyTabViewVisibility,Oe as attachRowPressFeedback,it as avatarInitials,Ke as boxChildMargin,qe as boxSpacingChanges,ze as buttonSlotAfterWrite,Be as buttonSlotDetaches,en as carouselDotClasses,tn as carouselNotifyPayload,nn as carouselPositionAtOffset,rn as carouselScrollOffset,Tt as clearAdwaitaNsAccent,ye as compiledIconNames,an as createCarouselState,Vt as createTabViewState,ut as dataGridCellClass,dt as dataGridItemSpec,ft as dataGridRowClass,pt as dataGridShapeKey,mt as dataGridTracksKey,An as evaluateBreakpointCondition,ge as extractIconPaths,_e as extractPathData,be as iconValueKind,re as isGtkIconSizeNick,xe as isIconAvailable,ce as isThemeIconColor,Ve as labelDisplayText,He as labelMarkupIsUnparseable,Xe as menuSheetActions,Ze as menuSheetRows,Je as normalizeBoxSpacing,on as normalizeCarouselPageWidth,ae as nsAlignment,le as onAdwaitaColorSchemeChanged,jn as parseBreakpointCondition,ht as parseDataGridWidth,Qe as presentMenuSheet,registerAdwaitaElements,Se as registerIcon,Ce as registeredIconNames,Ee as renderSymbolicIcon,we as resolveIconSource,$e as resolveMenuChoice,ue as setAdwaitaColorScheme,Pt as shortcutLabelDirection,Ft as shortcutLabelPlatform,It as shortcutLabelRenderPlan,pn as splitViewColumns,Ht as tabBarVisibility,Ut as tabCloseVisibilities,Wt as tabLabelText,Gt as tabPageVisibilities,Kt as tabTooltipText,qt as tabViewNotifyPayload,de as themeIconColor,fe as toggleAdwaitaColorScheme,Te as unregisterIcon};
@@ -0,0 +1,2 @@
1
+ declare const _default: () => Promise<void>;
2
+ export default _default;
@@ -1,5 +1,5 @@
1
1
  export { assertNativeScript, isNativeScript, isAndroid, isIOS } from '@gjsify/native-platform';
2
- export { NOTIFY_ACTIVE, NOTIFY_TEXT, ENTRY_ACTIVATE, NOTIFY_ENTRY_TEXT, ComboState, NOTIFY_SELECTED, NOTIFY_DROP_DOWN_SELECTED, SpinState, NOTIFY_VALUE, AdwSliderRow, NOTIFY_SLIDER_VALUE, ExpanderState, NOTIFY_EXPANDED, AdwImageButton, DEFAULT_ICON_BUTTON_ICON_SIZE, MENU_ITEM_ACTIVATED, DEFAULT_GTK_IMAGE_SIZE, DEFAULT_BOX_SPACING, GTK_BUTTON_CLICKED, GTK_BUTTON_LABEL_CLASS, buttonSlotAfterWrite, buttonSlotDetaches, boxChildMargin, boxSpacingChanges, normalizeBoxSpacing, labelDisplayText, labelMarkupIsUnparseable, BUTTON_CLICKED, AVATAR_DEFAULT_ICON, DEFAULT_AVATAR_SIZE, avatarInitials, DEFAULT_CLAMP_MAX_SIZE, AdwDataGrid, ROW_ACTIVATED, dataGridCellClass, dataGridItemSpec, dataGridRowClass, dataGridShapeKey, dataGridTracksKey, parseDataGridWidth, DATA_GRID_HEADER_CELL_CLASS, DATA_GRID_HEADER_ROW_CLASS, DATA_GRID_SECTION_CELL_CLASS, DEFAULT_SPINNER_SIZE, ACTIVATED, CLICKED, MENU_TAPPED, ToggleGroupState, NOTIFY_TOGGLE_SELECTED, applyAdwaitaNsAccent, clearAdwaitaNsAccent, ADWAITA_NS_ACCENT_RULES, adwaitaNsAccentColor, adwaitaNsAccentCss, SHORTCUT_LABEL_CAP_TEXT_CLASS, SHORTCUT_LABEL_CLASS, SHORTCUT_LABEL_DIMMED_CLASS, SHORTCUT_LABEL_DISABLED_CLASS, SHORTCUT_LABEL_KEYCAP_CLASS, SHORTCUT_LABEL_KEYS_CLASS, SHORTCUT_LABEL_SIDE_CLASS, SHORTCUT_LABEL_SPACED_CLASS, shortcutLabelDirection, shortcutLabelPlatform, shortcutLabelRenderPlan, NOTIFY_VISIBLE_CHILD, AdwViewSwitcherBase, NOTIFY_VIEW_SELECTED, DEFAULT_CAROUSEL_PAGE_WIDTH, NOTIFY_POSITION, NOTIFY_VISIBLE_PAGE, AdwSplitViewBase, NOTIFY_SHOW_SIDEBAR, NsNavigationSplitViewState, NsOverlaySplitViewState, splitViewColumns, NOTIFY_SIDEBAR_SELECTED, NOTIFY_OPEN, AdwToast, AdwToastQueue, DEFAULT_TOAST_TIMEOUT, TOAST_BUTTON_CLICKED, AdwAlertResponses, NOTIFY_RESPONSE, ABOUT_CLOSED, PREFERENCES_CLOSED, applyConstructProps, nsAlignment, GTK_ALIGN, attachRowPressFeedback, ICON_FALLBACK_NAME, compiledIconNames, iconValueKind, isIconAvailable, registerIcon, registeredIconNames, resolveIconSource, unregisterIcon, renderSymbolicIcon, extractIconPaths, extractPathData, ADWAITA_ICON_GRID, DEFAULT_ICON_COLOR, DEFAULT_ICON_COLOR_DARK, adwaitaColorScheme, isThemeIconColor, onAdwaitaColorSchemeChanged, setAdwaitaColorScheme, themeIconColor, toggleAdwaitaColorScheme, AdwBreakpoint, addBreakpoints, evaluateBreakpointCondition, parseBreakpointCondition, registerAdwaitaElements, } from './widgets/index.js';
2
+ export { NOTIFY_ACTIVE, NOTIFY_TEXT, ENTRY_ACTIVATE, NOTIFY_ENTRY_TEXT, ComboState, NOTIFY_SELECTED, NOTIFY_DROP_DOWN_SELECTED, SpinState, NOTIFY_VALUE, AdwSliderRow, NOTIFY_SLIDER_VALUE, ExpanderState, NOTIFY_EXPANDED, AdwImageButton, DEFAULT_ICON_BUTTON_ICON_SIZE, MENU_ITEM_ACTIVATED, DEFAULT_GTK_IMAGE_SIZE, DEFAULT_BOX_SPACING, GTK_BUTTON_CLICKED, GTK_BUTTON_LABEL_CLASS, buttonSlotAfterWrite, buttonSlotDetaches, boxChildMargin, boxSpacingChanges, normalizeBoxSpacing, labelDisplayText, labelMarkupIsUnparseable, BUTTON_CLICKED, AVATAR_DEFAULT_ICON, DEFAULT_AVATAR_SIZE, avatarInitials, DEFAULT_CLAMP_MAX_SIZE, AdwDataGrid, ROW_ACTIVATED, dataGridCellClass, dataGridItemSpec, dataGridRowClass, dataGridShapeKey, dataGridTracksKey, parseDataGridWidth, DATA_GRID_HEADER_CELL_CLASS, DATA_GRID_HEADER_ROW_CLASS, DATA_GRID_SECTION_CELL_CLASS, DEFAULT_SPINNER_SIZE, ACTIVATED, CLICKED, MENU_TAPPED, ToggleGroupState, NOTIFY_TOGGLE_SELECTED, applyAdwaitaNsAccent, clearAdwaitaNsAccent, ADWAITA_NS_ACCENT_RULES, adwaitaNsAccentColor, adwaitaNsAccentCss, SHORTCUT_LABEL_CAP_TEXT_CLASS, SHORTCUT_LABEL_CLASS, SHORTCUT_LABEL_DIMMED_CLASS, SHORTCUT_LABEL_DISABLED_CLASS, SHORTCUT_LABEL_KEYCAP_CLASS, SHORTCUT_LABEL_KEYS_CLASS, SHORTCUT_LABEL_SIDE_CLASS, SHORTCUT_LABEL_SPACED_CLASS, shortcutLabelDirection, shortcutLabelPlatform, shortcutLabelRenderPlan, NOTIFY_VISIBLE_CHILD, AdwViewSwitcherBase, NOTIFY_VIEW_SELECTED, DEFAULT_CAROUSEL_PAGE_WIDTH, NOTIFY_POSITION, NOTIFY_VISIBLE_PAGE, AdwSplitViewBase, NOTIFY_SHOW_SIDEBAR, NsNavigationSplitViewState, NsOverlaySplitViewState, splitViewColumns, NOTIFY_SIDEBAR_SELECTED, NOTIFY_OPEN, AdwToast, AdwToastQueue, DEFAULT_TOAST_TIMEOUT, TOAST_BUTTON_CLICKED, AdwAlertResponses, NOTIFY_RESPONSE, ABOUT_CLOSED, PREFERENCES_CLOSED, applyConstructProps, nsAlignment, GTK_ALIGN, DEFAULT_ICON_PIXEL_SIZE, GTK_ICON_SIZE_NICKS, GTK_ICON_SIZE_PIXELS, type GtkIconSizeNick, isGtkIconSizeNick, PIXEL_SIZE_UNSET, attachRowPressFeedback, ICON_FALLBACK_NAME, compiledIconNames, iconValueKind, isIconAvailable, registerIcon, registeredIconNames, resolveIconSource, unregisterIcon, renderSymbolicIcon, extractIconPaths, extractPathData, ADWAITA_ICON_GRID, DEFAULT_ICON_COLOR, DEFAULT_ICON_COLOR_DARK, adwaitaColorScheme, isThemeIconColor, onAdwaitaColorSchemeChanged, setAdwaitaColorScheme, themeIconColor, toggleAdwaitaColorScheme, AdwBreakpoint, addBreakpoints, evaluateBreakpointCondition, parseBreakpointCondition, registerAdwaitaElements, } from './widgets/index.js';
3
3
  export type { BoxOrientation, ButtonSlot, ButtonSlotWrite, NotifyActiveEventData, NotifyTextEventData, NotifyEntryTextEventData, AdwComboOption, ComboStateChange, ComboStateListener, NotifySelectedEventData, NotifyDropDownSelectedEventData, NotifyValueEventData, SpinStateChange, SpinStateListener, NotifySliderValueEventData, NotifyExpandedEventData, ExpanderStateListener, MenuItemActivatedEventData, MenuSheetPresenter, MenuSheetRow, MenuTappedEventData, RowActivatedEventData, DataGridItemSpec, NotifyToggleSelectedEventData, ToggleGroupStateChange, ToggleGroupStateListener, AccentRole, AccentRule, ShortcutLabelRenderPlan, ShortcutLabelViewSpec, AdwViewStackPage, NotifyVisibleChildEventData, AdwViewPage, NotifyViewSelectedEventData, NotifyPositionEventData, NotifyVisiblePageEventData, NotifyShowSidebarEventData, NsShowSidebarNotification, NsSplitViewHost, NsSplitViewState, NotifySidebarSelectedEventData, NotifyOpenEventData, AdwToastOptions, AdwToastQueueHandlers, AdwToastQueueOptions, ToastScheduler, ToastTimerHandle, NotifyResponseEventData, AdwAlertResponse, AdwResponseAppearance, AdwResponseOptions, OrderedConfirmResponses, ConstructProps, IconValueKind, SymbolicIconOptions, IconPath, AdwColorScheme, AdwBreakpointHandlers, BreakpointBound, BreakpointConditionGroup, BreakpointConditionLeaf, BreakpointConditionNode, BreakpointDimension, BreakpointSize, } from './widgets/index.js';
4
4
  export * as Adw from './namespace/adw.js';
5
5
  export * as Gtk from './namespace/gtk.js';
@@ -1,7 +1,16 @@
1
1
  import { GridLayout, Image } from '@nativescript/core';
2
+ import { type GtkIconSizeNick } from './gtk-icon-size.js';
2
3
  import { type ConstructProps } from './construct-props.js';
3
- /** Default symbolic-icon size, in DIPs — the Adwaita 16px icon grid. */
4
- export declare const DEFAULT_ICON_BUTTON_ICON_SIZE = 16;
4
+ /**
5
+ * The size this button's glyph draws at when neither size property was set, in DIPs — the Adwaita
6
+ * 16px symbolic grid.
7
+ *
8
+ * PUBLISHED NAME, kept pointing at {@link DEFAULT_ICON_PIXEL_SIZE} rather than renamed:
9
+ * it predates #1584's split and means what it always meant, a NUMBER of DIPs. Read it as
10
+ * `pixelSize`'s default; `iconSize` now defaults to the nick `'inherit'`, which resolves
11
+ * to this same number.
12
+ */
13
+ export declare const DEFAULT_ICON_BUTTON_ICON_SIZE: number;
5
14
  declare const AdwImageButton_base: (abstract new (...args: any[]) => {
6
15
  connect(eventName: string, callback: (self: /*elided*/ any, data: import("@nativescript/core").EventData) => void): number;
7
16
  disconnect(handlerId: number): void;
@@ -20,10 +29,15 @@ export declare class AdwImageButton extends AdwImageButton_base {
20
29
  private _iconColor;
21
30
  private _explicitColor;
22
31
  private _iconSize;
32
+ private _pixelSize;
23
33
  private _unsubScheme;
24
34
  constructor(props?: ConstructProps<AdwImageButton>);
25
35
  /** Adopt the active scheme's default fill (no-op if the caller pinned a colour). */
26
36
  private _syncThemeColor;
37
+ /** The size the glyph draws at right now: `pixelSize` when set, else `iconSize`. */
38
+ private get _renderedSize();
39
+ /** Resize the icon box and re-rasterise the glyph into it. */
40
+ private _applySize;
27
41
  /** Re-render the icon bitmap from the current svg / colour / size. */
28
42
  private _render;
29
43
  /**
@@ -37,9 +51,20 @@ export declare class AdwImageButton extends AdwImageButton_base {
37
51
  * the light/dark scheme) — for context colours that must survive both schemes. */
38
52
  get iconColor(): string;
39
53
  set iconColor(value: string);
40
- /** The icon size in DIPs (default 16). Re-renders + resizes the image box. */
41
- get iconSize(): number;
42
- set iconSize(raw: number | string);
54
+ /**
55
+ * `Gtk.Image:icon-size` on the glyph — one of `inherit`, `normal` (16 DIPs) or
56
+ * `large` (32). THE ENUM, not a number: for a size in DIPs use {@link pixelSize}.
57
+ * A value that is not a member throws, naming it and the three that are (#1584).
58
+ */
59
+ get iconSize(): GtkIconSizeNick;
60
+ set iconSize(value: GtkIconSizeNick);
61
+ /**
62
+ * `Gtk.Image:pixel-size` on the glyph — its edge length in DIPs, overriding
63
+ * {@link iconSize}. This is what `iconSize` did before #1584. It reads back `-1` while
64
+ * unset, as `gtk_image_get_pixel_size` does; assigning a non-positive value clears it.
65
+ */
66
+ get pixelSize(): number;
67
+ set pixelSize(raw: number | string);
43
68
  /** The underlying icon {@link Image} (e.g. to tweak alignment). */
44
69
  get image(): Image;
45
70
  }
@@ -12,8 +12,14 @@
12
12
  * one that admits two impossible ones and says so when they arrive.
13
13
  */
14
14
  export type ConstructProps<T> = Partial<{
15
- [K in keyof T as T[K] extends (...args: never[]) => unknown ? never : K]: K extends AlignmentProp ? T[K] | number : T[K];
15
+ [K in keyof T as T[K] extends (...args: never[]) => unknown ? never : K]: K extends EnumProp ? T[K] | number : T[K];
16
16
  }>;
17
+ /**
18
+ * Every key this bag reads as a GIR ENUM, so `| number` is admitted for exactly those and
19
+ * nowhere else. ADR 0034 § 4's second spelling: a nick is what an XML attribute can carry,
20
+ * and the constant is what a snippet ported off GJS carries.
21
+ */
22
+ export type EnumProp = AlignmentProp | IconSizeProp;
17
23
  /**
18
24
  * The NativeScript properties whose value this package reads as a `Gtk.Align`.
19
25
  *
@@ -50,6 +56,20 @@ declare const ALIGNMENT_AXES: {
50
56
  * is the one caller the second spelling exists for.
51
57
  */
52
58
  export type AlignmentProp = keyof typeof ALIGNMENT_AXES;
59
+ /**
60
+ * The keys the bag reads as a `Gtk.IconSize` — the port's OWN property, unlike the two
61
+ * alignment axes, which are NativeScript's.
62
+ *
63
+ * A table of one, and it is a table for the same reason `ALIGNMENT_AXES` is: the runtime key
64
+ * set and the type widening are derived from ONE declaration, so the type cannot admit a key
65
+ * the applier does not coerce, nor refuse one it does. `GtkImage` and `AdwImageButton` both
66
+ * spell it `iconSize` (#1584), and no other widget on this surface has a key of that name.
67
+ */
68
+ declare const ICON_SIZE_PROPS: {
69
+ readonly iconSize: true;
70
+ };
71
+ /** The keys {@link ICON_SIZE_PROPS} declares — {@link ConstructProps} widens exactly these. */
72
+ export type IconSizeProp = keyof typeof ICON_SIZE_PROPS;
53
73
  /**
54
74
  * A `Gtk.Align` value — the nick, or the constant a GJS caller's `Gtk.Align.CENTER` is —
55
75
  * as the NativeScript alignment for `axis`. Any other value is NativeScript's own and is
@@ -0,0 +1,96 @@
1
+ /**
2
+ * Every `Gtk.IconSize` member, in GIR declaration order.
3
+ *
4
+ * Held against `GtkIconSizeNick` in `packages/framework/gtk-host/src/generated/props.ts` by
5
+ * arm 7 of `scripts/check-nativescript-xml-doors.mjs` — in-repo, GIR-derived, emitted by a
6
+ * generator that has never heard of this port — so this array is a copy that cannot drift
7
+ * rather than a second source. No member is an alias, so unlike `Gtk.Align` the positions
8
+ * ARE the values.
9
+ */
10
+ export declare const GTK_ICON_SIZE_NICKS: readonly ["inherit", "normal", "large"];
11
+ /** One of the three `Gtk.IconSize` members, spelled as its nick. */
12
+ export type GtkIconSizeNick = (typeof GTK_ICON_SIZE_NICKS)[number];
13
+ /**
14
+ * What each member renders at, in DIPs — the measurement in this file's header.
15
+ *
16
+ * `inherit` means "take the size from the context" on GTK, where a parent's
17
+ * `-gtk-icon-size` cascades. NativeScript has no such cascade — an `Image` is sized by its
18
+ * own `width`/`height` and nothing inherits one — so there is nothing here to inherit FROM,
19
+ * and the honest reading of `inherit` is the size GTK itself falls back to when no ancestor
20
+ * sets one, which the measurement puts at 16. That it equals `normal` is not a coincidence
21
+ * to be tidied away: the two agree on GTK too, and they would stop agreeing the day this
22
+ * port grows a context that carries a size.
23
+ */
24
+ export declare const GTK_ICON_SIZE_PIXELS: Readonly<Record<GtkIconSizeNick, number>>;
25
+ /** The size an icon draws at when neither property was set — the Adwaita 16px symbolic grid. */
26
+ export declare const DEFAULT_ICON_PIXEL_SIZE: number;
27
+ /**
28
+ * Every `Gtk.IconSize` member, nick to constant.
29
+ *
30
+ * The positions ARE the values here, and that is a fact about THIS enum rather than a
31
+ * shortcut: no member of `Gtk.IconSize` is an alias, so nothing shifts below anything.
32
+ * `Gtk.Align` is the counter-example the sibling file is built around — `GTK_ALIGN_BASELINE`
33
+ * was deprecated into an alias in GTK 4.12, so 2 of its 7 members are not their position —
34
+ * which is why this is DERIVED from the nick order and then held against the committed,
35
+ * typelib-read `ENUM_VALUES` in `packages/framework/gtk-host/src/generated/enum-values.mts`
36
+ * by arm 7 of `check-nativescript-xml-doors.mjs`. A derivation that happens to be right is
37
+ * worth nothing without the oracle beside it.
38
+ */
39
+ export declare const GTK_ICON_SIZE: Readonly<Record<GtkIconSizeNick, number>>;
40
+ /** Is `value` one of the three members? */
41
+ export declare function isGtkIconSizeNick(value: unknown): value is GtkIconSizeNick;
42
+ /**
43
+ * A `Gtk.IconSize` value as its NICK — the nick itself, or the constant a GJS caller's
44
+ * `Gtk.IconSize.LARGE` is.
45
+ *
46
+ * A NON-NUMBER goes back unchanged, for the SETTER to refuse with the one message that names
47
+ * the three members — one refusal, not two. A number that is no member is refused HERE
48
+ * instead, and the two are not the same mistake: by writing a number the caller has said
49
+ * "constant", so the setter could only report it as a bad nick, where `24` is a size in DIPs
50
+ * written under the wrong name and the throw can say exactly that.
51
+ *
52
+ * ADR 0034 § 4's second spelling, and it lives HERE rather than in the setter on purpose: a
53
+ * setter that widened its declared type to admit the constant would drag the number into the
54
+ * XML ATTRIBUTE door, which has no coercer. The construct-props bag is the one door that
55
+ * carries a real JS value, so it is the one that coerces — the arrangement `Gtk.Align`
56
+ * already has in `construct-props.ts`.
57
+ */
58
+ export declare function iconSizeNickOf(value: unknown): unknown;
59
+ /**
60
+ * `value` as a `Gtk.IconSize` member, or a THROW naming what it was and what is accepted.
61
+ *
62
+ * The one setter in this package that refuses rather than falling back, and the reason is
63
+ * the defect it replaces: a number setter fed `'large'` substituted its default, so a typo,
64
+ * a value copied out of the GTK documentation and a deliberate choice all produced the same
65
+ * silent 16 DIPs. There are exactly three legal values and no range to be lenient about, so
66
+ * "not one of them" is a caller mistake and nothing else — the same reasoning
67
+ * `parseWidgetSelector`'s empty-selector refusal follows, and the opposite of `xmlNumber`,
68
+ * which is lenient because a number genuinely has a sensible default.
69
+ *
70
+ * `fallback` is NAMED IN THE MESSAGE and never returned — this throws. The widget's current
71
+ * setting survives because nothing was assigned to it, not because of this parameter; the
72
+ * parameter is there so the error can say which setting that is.
73
+ */
74
+ export declare function gtkIconSizeNick(value: unknown, fallback: GtkIconSizeNick): GtkIconSizeNick;
75
+ /**
76
+ * GTK's "`pixel-size` is not set" sentinel — what `gtk_image_get_pixel_size` answers when
77
+ * the icon size is in charge.
78
+ *
79
+ * A sentinel rather than `null` because it is the value the PROPERTY carries: a getter that
80
+ * answered the size the image happens to draw at would make `image.pixelSize =
81
+ * image.pixelSize` PIN that size, and the setter falls back to the getter (every number
82
+ * setter in this package does — `xmlNumber(raw, this.<prop>)`), so an unparseable
83
+ * assignment would pin it too.
84
+ */
85
+ export declare const PIXEL_SIZE_UNSET = -1;
86
+ /** An assignment to `pixel-size` as the value to store: a positive size, or the sentinel. */
87
+ export declare function storedPixelSize(value: number): number;
88
+ /**
89
+ * The size to draw at, in DIPs: the explicit `pixelSize` when there is one, else what
90
+ * `iconSize` resolves to.
91
+ *
92
+ * That precedence is `Gtk.Image`'s own — `gtk_image_set_pixel_size` documents -1 as "unset,
93
+ * the icon size decides" and any other value as an override. Any non-positive or non-finite
94
+ * value reads as unset here, because a 0-DIP image is not a rendering anyone asked for.
95
+ */
96
+ export declare function iconPixelSize(iconSize: GtkIconSizeNick, pixelSize: number): number;
@@ -1,7 +1,16 @@
1
1
  import { Image } from '@nativescript/core';
2
+ import { type GtkIconSizeNick } from './gtk-icon-size.js';
2
3
  import { type ConstructProps } from './construct-props.js';
3
- /** Default decorative-icon size, in DIPs — the Adwaita 16px symbolic grid. */
4
- export declare const DEFAULT_GTK_IMAGE_SIZE = 16;
4
+ /**
5
+ * The size this image draws at when neither size property was set, in DIPs — the Adwaita
6
+ * 16px symbolic grid.
7
+ *
8
+ * PUBLISHED NAME, kept pointing at {@link DEFAULT_ICON_PIXEL_SIZE} rather than renamed:
9
+ * it predates #1584's split and means what it always meant, a NUMBER of DIPs. Read it as
10
+ * `pixelSize`'s default; `iconSize` now defaults to the nick `'inherit'`, which resolves
11
+ * to this same number.
12
+ */
13
+ export declare const DEFAULT_GTK_IMAGE_SIZE: number;
5
14
  declare const GtkImage_base: (abstract new (...args: any[]) => {
6
15
  connect(eventName: string, callback: (self: /*elided*/ any, data: import("@nativescript/core").EventData) => void): number;
7
16
  disconnect(handlerId: number): void;
@@ -18,10 +27,15 @@ export declare class GtkImage extends GtkImage_base {
18
27
  private _iconColor;
19
28
  private _explicitColor;
20
29
  private _iconSize;
30
+ private _pixelSize;
21
31
  private _unsubScheme;
22
32
  constructor(props?: ConstructProps<GtkImage>);
23
33
  /** Adopt the active scheme's default fill (no-op if the caller pinned a colour). */
24
34
  private _syncThemeColor;
35
+ /** The size this image draws at right now: `pixelSize` when set, else `iconSize`. */
36
+ private get _renderedSize();
37
+ /** Resize the image box and re-rasterise the glyph into it. */
38
+ private _applySize;
25
39
  private _render;
26
40
  /**
27
41
  * The icon to render: an Adwaita icon NAME (`'list-add-symbolic'`) or an Adwaita
@@ -35,8 +49,28 @@ export declare class GtkImage extends GtkImage_base {
35
49
  * button or destructive red, which must survive both schemes. */
36
50
  get iconColor(): string;
37
51
  set iconColor(value: string);
38
- /** The icon size in DIPs (default 16). Re-renders + resizes the image box. */
39
- get iconSize(): number;
40
- set iconSize(raw: number | string);
52
+ /**
53
+ * `Gtk.Image:icon-size` — one of `inherit`, `normal` (16 DIPs) or `large` (32).
54
+ *
55
+ * THE ENUM, not a number, and that is the whole of #1584: this name used to take a
56
+ * count of DIPs, so `<gtk:Image iconSize="large" />` — which is what a reader of the
57
+ * GTK documentation writes — failed to parse, fell back, and rendered at 16 with
58
+ * nothing reported. For a size in DIPs use {@link pixelSize}, which is the GTK
59
+ * property that means one. A value that is not a member THROWS, naming it and the
60
+ * three that are accepted: there is no range here to be lenient about.
61
+ */
62
+ get iconSize(): GtkIconSizeNick;
63
+ set iconSize(value: GtkIconSizeNick);
64
+ /**
65
+ * `Gtk.Image:pixel-size` — the edge length in DIPs, overriding {@link iconSize}.
66
+ *
67
+ * This is what the property called `iconSize` did before #1584, under the name GTK
68
+ * gives it. It reads back `-1` while unset, which is what `gtk_image_get_pixel_size`
69
+ * answers and NOT the size the image draws at: a getter that answered the drawn size
70
+ * would make `image.pixelSize = image.pixelSize` pin it. Assigning any non-positive
71
+ * value clears the override and hands the size back to {@link iconSize}.
72
+ */
73
+ get pixelSize(): number;
74
+ set pixelSize(raw: number | string);
41
75
  }
42
76
  export {};
@@ -94,6 +94,7 @@ export { attachRowPressFeedback } from './row-press.js';
94
94
  export { applyConstructProps, nsAlignment } from './construct-props.js';
95
95
  export type { ConstructProps } from './construct-props.js';
96
96
  export { GTK_ALIGN } from './gtk-align.js';
97
+ export { DEFAULT_ICON_PIXEL_SIZE, GTK_ICON_SIZE_NICKS, GTK_ICON_SIZE_PIXELS, type GtkIconSizeNick, isGtkIconSizeNick, PIXEL_SIZE_UNSET, } from './gtk-icon-size.js';
97
98
  export { ICON_FALLBACK_NAME, compiledIconNames, iconValueKind, isIconAvailable, registerIcon, registeredIconNames, resolveIconSource, unregisterIcon, } from './icon-theme.js';
98
99
  export type { IconValueKind } from './icon-theme.js';
99
100
  export { ADWAITA_ICON_GRID, DEFAULT_ICON_COLOR, DEFAULT_ICON_COLOR_DARK, extractIconPaths, extractPathData, renderSymbolicIcon, } from './icons.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gjsify/adwaita-nativescript",
3
- "version": "0.49.0",
3
+ "version": "0.50.0",
4
4
  "description": "Native Adwaita widgets for the NativeScript runtime — real NativeScript components (StackLayout/GridLayout/Switch/Label) styled like Libadwaita, not a webview",
5
5
  "type": "module",
6
6
  "module": "lib/esm/index.js",
@@ -51,10 +51,10 @@
51
51
  "design-system"
52
52
  ],
53
53
  "dependencies": {
54
- "@gjsify/adwaita-core": "^0.49.0",
55
- "@gjsify/adwaita-fonts": "^0.49.0",
56
- "@gjsify/adwaita-icons": "^0.49.0",
57
- "@gjsify/native-platform": "^0.49.0"
54
+ "@gjsify/adwaita-core": "^0.50.0",
55
+ "@gjsify/adwaita-fonts": "^0.50.0",
56
+ "@gjsify/adwaita-icons": "^0.50.0",
57
+ "@gjsify/native-platform": "^0.50.0"
58
58
  },
59
59
  "peerDependencies": {
60
60
  "@nativescript/core": "*"
@@ -65,8 +65,8 @@
65
65
  }
66
66
  },
67
67
  "devDependencies": {
68
- "@gjsify/cli": "^0.49.0",
69
- "@gjsify/unit": "^0.49.0",
68
+ "@gjsify/cli": "^0.50.0",
69
+ "@gjsify/unit": "^0.50.0",
70
70
  "@types/node": "^25.9.2",
71
71
  "typescript": "^6.0.3"
72
72
  },