@gjsify/adwaita-core 0.47.0 → 0.48.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.
@@ -0,0 +1 @@
1
+ import"./_virtual/_rolldown/runtime.js";const e={value:0,lower:0,upper:100,stepIncrement:1,pageIncrement:1,pageSize:0},t={...e,value:NaN};function finite(e,t){return typeof e==`number`&&Number.isFinite(e)?e:t}function adjustmentRange(e){return[e.lower,Math.max(e.lower,e.upper-e.pageSize)]}function clampAdjustmentValue(e,t){let[n,r]=adjustmentRange(e);return typeof t!=`number`||Number.isNaN(t)?n:Math.min(r,Math.max(n,t))}function snapAdjustmentValue(e,t){let n=clampAdjustmentValue(e,t),[r,i]=adjustmentRange(e),a=(i-r)/e.stepIncrement,o=Math.floor(a+Math.max(1,Math.abs(a))*1e-12),s=Math.min(o,Math.max(0,Math.round((n-r)/e.stepIncrement)));return Math.min(i,Math.max(r,r+s*e.stepIncrement))}function normalizeAdjustment(n,r=t){let i=n??{},a=finite(i.lower,r.lower),o=Math.max(a,finite(i.upper,r.upper)),s=finite(i.stepIncrement,r.stepIncrement),c=s>0?s:r.stepIncrement>0?r.stepIncrement:e.stepIncrement,l=r.pageIncrement===r.stepIncrement,u=finite(i.pageIncrement,l?c:r.pageIncrement),d={value:0,lower:a,upper:o,stepIncrement:c,pageIncrement:u>0?u:c,pageSize:Math.max(0,finite(i.pageSize,r.pageSize))};return d.value=clampAdjustmentValue(d,typeof i.value==`number`?i.value:r.value),d}const n=[`value`,`lower`,`upper`,`stepIncrement`,`pageIncrement`,`pageSize`];function parseAdjustment(e){if(!e)return{};let t;try{t=JSON.parse(e)}catch{return{}}if(typeof t!=`object`||!t||Array.isArray(t))return{};let r=t,i={};for(let e of n){let t=r[e];typeof t==`number`&&(i[e]=t)}return i}var SpinState=class{constructor(){this._adjustment=normalizeAdjustment(),this._valueSet=!1,this._listeners=new Set,this._rangeListeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}subscribeChanged(e){return this._rangeListeners.add(e),()=>{this._rangeListeners.delete(e)}}_emit(e){let t={value:this._adjustment.value,interactive:e};for(let e of[...this._listeners])e(t)}_emitChanged(){let e=this._adjustment;for(let t of[...this._rangeListeners])t(e)}_bump(e){let t=clampAdjustmentValue(this._adjustment,this._adjustment.value+e);return t===this._adjustment.value?!1:(this._valueSet=!0,this._adjustment={...this._adjustment,value:t},this._emit(!0),!0)}get adjustment(){return{...this._adjustment}}get value(){return this._adjustment.value}configure(e){let t=this._adjustment,n=normalizeAdjustment(e,this._valueSet?t:{...t,value:NaN});typeof e?.value==`number`&&Number.isFinite(e.value)&&(this._valueSet=!0);let r=n.lower!==t.lower||n.upper!==t.upper||n.stepIncrement!==t.stepIncrement||n.pageIncrement!==t.pageIncrement||n.pageSize!==t.pageSize,i=n.value!==t.value;return!r&&!i?!1:(this._adjustment=n,r&&this._emitChanged(),i&&this._emit(!1),!0)}setValue(e){Number.isFinite(e)&&(this._valueSet=!0);let t=clampAdjustmentValue(this._adjustment,e);return t===this._adjustment.value?!1:(this._adjustment={...this._adjustment,value:t},this._emit(!1),!0)}setValueInteractive(e){Number.isFinite(e)&&(this._valueSet=!0);let t=clampAdjustmentValue(this._adjustment,e);return t===this._adjustment.value?!1:(this._adjustment={...this._adjustment,value:t},this._emit(!0),!0)}increment(){return this._bump(this._adjustment.stepIncrement)}decrement(){return this._bump(-this._adjustment.stepIncrement)}};export{e as ADW_ADJUSTMENT_DEFAULTS,SpinState,adjustmentRange,clampAdjustmentValue,normalizeAdjustment,parseAdjustment,snapAdjustmentValue};
@@ -0,0 +1 @@
1
+ const e={value:0,lower:0,upper:100,stepIncrement:1,pageIncrement:1,pageSize:0},t=[{rule:`an empty adjustment is 0…100 step 1 — the shared default, not GTK's 0…0 step 0`,input:{},adjustment:e},{rule:`the unwritten fields come from that default`,input:{upper:10},adjustment:{...e,upper:10}},{rule:`a value authored ABOVE the range lands on the upper bound`,input:{lower:0,upper:10,value:99},adjustment:{...e,upper:10,value:10}},{rule:`a value authored BELOW the range lands on the lower bound`,input:{lower:5,upper:10,value:1},adjustment:{...e,lower:5,upper:10,value:5}},{rule:`a zero step becomes 1 — GTK's default step is a stepper that cannot move`,input:{stepIncrement:0},adjustment:e},{rule:`the page increment follows the step until one is authored`,input:{stepIncrement:5},adjustment:{...e,stepIncrement:5,pageIncrement:5}},{rule:`an upper below the lower collapses the range to a point rather than inverting it`,input:{lower:10,upper:2,value:7},adjustment:{...e,lower:10,upper:10,value:10}},{rule:`a page size takes its bite out of the top: the value may reach upper - pageSize`,input:{lower:0,upper:100,pageSize:20,value:95},adjustment:{...e,pageSize:20,value:80}},{rule:`an unwritten value on a range that excludes zero lands at the BOTTOM, not the top`,input:{lower:-100,upper:-50},adjustment:{...e,lower:-100,upper:-50,value:-100}}],n=[{rule:`reads the fields the JSON names`,raw:`{"lower":1,"upper":20}`,input:{lower:1,upper:20}},{rule:`names no value where the JSON names none, so an authored value survives the write`,raw:`{"upper":20}`,input:{upper:20}},{rule:`drops a key an adjustment does not have`,raw:`{"min":1,"upper":20}`,input:{upper:20}},{rule:`drops a field that is not a number`,raw:`{"upper":"20"}`,input:{}},{rule:`absent is nothing authored`,raw:null,input:{}},{rule:`unparseable is nothing authored, and not a throw`,raw:`{lower:1`,input:{}},{rule:`well-formed JSON that is not an object is nothing authored`,raw:`[1,2]`,input:{}}],r=[{rule:`ticks are counted from the LOWER bound, not from zero`,input:{lower:1,upper:10,stepIncrement:3},from:5,snapped:4},{rule:`and it rounds to the nearer of the two`,input:{lower:1,upper:10,stepIncrement:3},from:6,snapped:7},{rule:`a drag past the top clamps first, so an upper off the grid is not reachable`,input:{lower:0,upper:10,stepIncrement:3},from:99,snapped:9},{rule:`an upper ON the grid is reachable`,input:{lower:0,upper:9,stepIncrement:3},from:99,snapped:9},{rule:`a drag below the bottom lands on the lower bound`,input:{lower:16,upper:64,stepIncrement:4},from:-99,snapped:16},{rule:`a value already on a tick does not move`,input:{lower:0,upper:10,stepIncrement:2},from:6,snapped:6},{rule:`an upper bound off the grid is not reachable, even when the drag ends ON it`,input:{lower:0,upper:10,stepIncrement:4},from:10,snapped:8},{rule:`an upper bound ON the grid is reachable, decimal step and all`,input:{lower:0,upper:.3,stepIncrement:.1},from:.3,snapped:.3},{rule:`and a tick below it is exact rather than one step off the accumulated sum`,input:{lower:0,upper:.3,stepIncrement:.1},from:.21,snapped:.2}];export{t as ADJUSTMENT_AUTHORED_VECTORS,n as ADJUSTMENT_PARSE_VECTORS,r as ADJUSTMENT_SNAP_VECTORS};
@@ -1 +1 @@
1
- import{ABOUT_DIALOG_CREDITS_LEGAL_VECTORS as e,ABOUT_DIALOG_DETAILS_VECTORS as t,ABOUT_DIALOG_HEADER_VECTORS as n,ABOUT_DIALOG_LABEL_VECTORS as r,ABOUT_DIALOG_SUPPORT_VECTORS as i,CREDITS_SECTIONS_VECTORS as a,CREDIT_PERSON_VECTORS as o,LEGAL_SECTION_VECTORS as s,LICENSE_INFO_VECTORS as c,LICENSE_SETTER_VECTORS as l,LICENSE_SPDX_VECTORS as u,LICENSE_TEXT_VECTORS as d,TRANSLATOR_CREDITS_VECTORS as f}from"./about-dialog.js";import{ACCENT_COLOR_VECTORS as p}from"./accent.js";import{ACTION_ROW_ACTIVATION_VECTORS as m,BUTTON_ROW_ACTIVATABLE_VECTORS as h,BUTTON_ROW_ICON_VECTORS as g,LABEL_VISIBILITY_VECTORS as _,SWITCH_ROW_NOTIFY_VECTORS as v,WINDOW_TITLE_VECTORS as y}from"./action-row.js";import{AVATAR_COLOR_VECTORS as b,AVATAR_FONT_SIZE_VECTORS as x,AVATAR_INITIALS_VECTORS as S,AVATAR_MODE_VECTORS as C}from"./avatar.js";import{BANNER_BUTTON_STYLE_PARSE_VECTORS as w,BANNER_BUTTON_STYLE_VECTORS as T,BANNER_BUTTON_TEXT_VECTORS as E,BANNER_BUTTON_VISIBLE_VECTORS as D,BANNER_DEFAULT_VECTORS as O}from"./banner.js";import{BREAKPOINT_PICK_VECTORS as k,BREAKPOINT_TRANSITION_VECTORS as A}from"./breakpoint-bin.js";import{BUTTON_CONTENT_DEFAULT_VECTORS as j,BUTTON_CONTENT_ELLIPSIZE_VECTORS as M,BUTTON_CONTENT_ICON_VECTORS as N,BUTTON_CONTENT_LABEL_VECTORS as P,BUTTON_CONTENT_STYLE_TARGET_VECTORS as F,BUTTON_CONTENT_TEXT_VECTORS as I}from"./button-content.js";import{BUTTON_STYLE_CLASS_VECTORS as L}from"./button.js";import{CAROUSEL_CLAMP_VECTORS as R,CAROUSEL_NAVIGATE_VECTORS as z,CAROUSEL_PAGE_ALLOCATION_VECTORS as B,CAROUSEL_PAGE_AT_POSITION_VECTORS as V,CAROUSEL_PAGE_LIST_VECTORS as H,CAROUSEL_PROPERTY_DEFAULT_VECTORS as U,CAROUSEL_RANGE_VECTORS as W,CAROUSEL_REORDER_SHIFT_VECTORS as G,CAROUSEL_REVEAL_VECTORS as K,CAROUSEL_SIZES_FROM_SNAP_POINTS_VECTORS as q,CAROUSEL_SNAP_POINT_VECTORS as J,CAROUSEL_WHEEL_LOCKOUT_VECTORS as Y,CAROUSEL_WHEEL_VECTORS as X}from"./carousel.js";import{RADIO_GROUP_VECTORS as Z}from"./checks.js";import{CLAMP_ALLOCATE_VECTORS as Q,CLAMP_CHILD_SIZE_VECTORS as $,CLAMP_PROPERTY_VECTORS as ee,CLAMP_SIZE_FROM_CHILD_VECTORS as te,CLAMP_THRESHOLD_VECTORS as ne,SPINNER_GEOMETRY_VECTORS as re,SPINNER_SIZE_VECTORS as ie,TOOLBAR_VIEW_ALLOCATE_VECTORS as ae,TOOLBAR_VIEW_CLASS_VECTORS as oe,TOOLBAR_VIEW_CONTENT_FOR_SIZE_VECTORS as se,TOOLBAR_VIEW_MEASURE_VECTORS as ce}from"./chrome.js";import{DATA_GRID_CELL_TEXT_VECTORS as le,DATA_GRID_COLUMN_CLASS_VECTORS as ue,DATA_GRID_COLUMN_NORMALIZE_VECTORS as de,DATA_GRID_INTERACTIVE_VECTORS as fe,DATA_GRID_TRACK_VECTORS as pe,DATA_GRID_VARIANT_VECTORS as me}from"./data-grid.js";import{BOTTOM_SHEET_CLOSE_VECTORS as he,BOTTOM_SHEET_PRESENTATION_VECTORS as ge,runBottomSheetSteps as _e}from"./dialog.js";import{ENTRY_MAX_LENGTH_VECTORS as ve,ENTRY_ROW_ACTIVATION_VECTORS as ye,ENTRY_ROW_GUARD_VECTORS as be,ENTRY_ROW_STATE_VECTORS as xe,ENTRY_TEXT_LENGTH_VECTORS as Se,PASSWORD_ENTRY_ROW_VECTORS as Ce,PASSWORD_REVEAL_GUARD_VECTORS as we}from"./entry-row.js";import{HEADER_BAR_PACK_VECTORS as Te,HEADER_BAR_TITLE_SOURCE_VECTORS as Ee,HEADER_BAR_TITLE_WIDGET_VECTORS as De}from"./header-bar.js";import{COMBO_CHOOSER_VECTORS as Oe,COMBO_SELECTION_VECTORS as ke}from"./rows.js";import{VIEW_STACK_ICON_NAME_VECTORS as Ae,VIEW_STACK_PAGE_VECTORS as je,VIEW_STACK_VECTORS as Me}from"./view-stack.js";import{NAVIGATION_VIEW_VECTORS as Ne,collectNavigationState as Pe,navigationEventLog as Fe,runNavigationSteps as Ie}from"./navigation-view.js";import{SIDEBAR_ACTIVATION_VECTORS as Le,SIDEBAR_CLAMP_VECTORS as Re,SIDEBAR_FILTER_VECTORS as ze,SIDEBAR_ITEMS_CHANGED_VECTORS as Be,SIDEBAR_ITEM_FLAG_VECTORS as Ve,SIDEBAR_MODEL_VECTORS as He,SIDEBAR_MODE_VECTORS as Ue}from"./sidebar.js";import{ADW_LENGTH_UNIT_VECTORS as We,GLIB_CLAMP_VECTORS as Ge,NATURAL_SIDEBAR_WIDTH_VECTORS as Ke,NAVIGATION_ACTION_VECTORS as qe,NAVIGATION_SPLIT_VIEW_LAYOUT_VECTORS as Je,NAVIGATION_STACK_VECTORS as Ye,OVERLAY_COLLAPSE_VECTORS as Xe,OVERLAY_SPLIT_VIEW_LAYOUT_VECTORS as Ze,OVERLAY_SWIPE_AREA_VECTORS as Qe,OVERLAY_SWIPE_CANCEL_VECTORS as $e,OVERLAY_SWIPE_RELEASE_VECTORS as et,OVERLAY_SWIPE_SNAP_POINT_VECTORS as tt,OVERLAY_SWIPE_START_VECTORS as nt,SIDEBAR_BOUNDS_VECTORS as rt,SIDEBAR_WIDTH_VECTORS as it,SPLIT_VIEW_MEASURE_VECTORS as at,TAGS_CONFLICT_VECTORS as ot}from"./split-view.js";import{MENU_BUTTON_DIRECTION_VECTORS as st,SPLIT_BUTTON_CONTENT_VECTORS as ct,SPLIT_BUTTON_DIRECTION_VECTORS as lt,SPLIT_BUTTON_DROPDOWN_VECTORS as ut,SPLIT_BUTTON_MENU_ACTIVATION_VECTORS as dt,SPLIT_BUTTON_MENU_PARSE_VECTORS as ft,SPLIT_BUTTON_ROOT_STATE_VECTORS as pt,SPLIT_BUTTON_STYLE_CLASS_VECTORS as mt,SPLIT_BUTTON_TOOLTIP_VECTORS as ht}from"./split-button.js";import{INLINE_TOGGLE_VECTORS as gt,INLINE_TOOLTIP_VECTORS as _t,VIEW_SWITCHER_BADGE_VECTORS as vt,VIEW_SWITCHER_BAR_REVEAL_VECTORS as yt,VIEW_SWITCHER_BAR_VECTORS as bt,VIEW_SWITCHER_BUTTON_VECTORS as xt,VIEW_SWITCHER_BUTTON_VISIBILITY_VECTORS as St,VIEW_SWITCHER_DRAG_VECTORS as Ct,VIEW_SWITCHER_ICON_VECTORS as wt,VIEW_SWITCHER_MNEMONIC_VECTORS as Tt,VIEW_SWITCHER_REBUILD_VECTORS as Et,VIEW_SWITCHER_SELECTION_VECTORS as Dt,createViewSwitcherClock as Ot}from"./view-switcher.js";import{TABS_REVEALED_VECTORS as kt,TAB_CLOSE_VISIBLE_VECTORS as At,TAB_DESCENDANT_VECTORS as jt,TAB_ICON_STATE_VECTORS as Mt,TAB_PAGE_DESCRIPTOR_VECTORS as Nt,TAB_SUCCESSOR_VECTORS as Pt,TAB_TOOLTIP_VECTORS as Ft,TAB_VIEW_VECTORS as It,applyTabViewOp as Lt,seedTabViewPages as Rt,tabViewClosing as zt,tabViewOrder as Bt}from"./tab-view.js";import{CASE_FOLD_VECTORS as Vt,MAKE_COMPARABLE_VECTORS as Ht,PREFERENCES_GROUP_HEADER_VECTORS as Ut,PREFERENCES_SEARCH_PAGES as Wt,PREFERENCES_SEARCH_VECTORS as Gt,ROW_MATCH_VECTORS as Kt,SEARCH_CORPUS_VECTORS as qt,SEARCH_ROW_SUBTITLE_VECTORS as Jt,STRIP_MARKUP_VECTORS as Yt,STRIP_MNEMONIC_VECTORS as Xt}from"./preferences.js";import{POPOVER_KEY_VECTORS as Zt,POPOVER_SURFACE_VECTORS as Qt}from"./popover.js";import{SHORTCUT_LABEL_VECTORS as $t,formatShortcutLabelNodes as en}from"./shortcut-label.js";import{SPINNER_ARC_ENVELOPE as tn,SPINNER_ARC_PHASE_VECTORS as nn,SPINNER_ARC_TOLERANCE as rn,SPINNER_CONSTANT_VECTORS as an}from"./spinner.js";import{WRAP_BOX_CHILD_ORDER_VECTORS as on,WRAP_BOX_LENGTH_VECTORS as sn,WRAP_BOX_LINE_VECTORS as cn,WRAP_BOX_NATURAL_LENGTH_VECTORS as ln,WRAP_BOX_NOTIFY_PROPERTIES as un,WRAP_BOX_POLICY_VECTORS as dn,WRAP_BOX_SPACING_NOTIFY_VECTORS as fn,WRAP_BOX_SPACING_VECTORS as pn}from"./wrap-box.js";export{e as ABOUT_DIALOG_CREDITS_LEGAL_VECTORS,t as ABOUT_DIALOG_DETAILS_VECTORS,n as ABOUT_DIALOG_HEADER_VECTORS,r as ABOUT_DIALOG_LABEL_VECTORS,i as ABOUT_DIALOG_SUPPORT_VECTORS,p as ACCENT_COLOR_VECTORS,m as ACTION_ROW_ACTIVATION_VECTORS,We as ADW_LENGTH_UNIT_VECTORS,b as AVATAR_COLOR_VECTORS,x as AVATAR_FONT_SIZE_VECTORS,S as AVATAR_INITIALS_VECTORS,C as AVATAR_MODE_VECTORS,w as BANNER_BUTTON_STYLE_PARSE_VECTORS,T as BANNER_BUTTON_STYLE_VECTORS,E as BANNER_BUTTON_TEXT_VECTORS,D as BANNER_BUTTON_VISIBLE_VECTORS,O as BANNER_DEFAULT_VECTORS,he as BOTTOM_SHEET_CLOSE_VECTORS,ge as BOTTOM_SHEET_PRESENTATION_VECTORS,k as BREAKPOINT_PICK_VECTORS,A as BREAKPOINT_TRANSITION_VECTORS,j as BUTTON_CONTENT_DEFAULT_VECTORS,M as BUTTON_CONTENT_ELLIPSIZE_VECTORS,N as BUTTON_CONTENT_ICON_VECTORS,P as BUTTON_CONTENT_LABEL_VECTORS,F as BUTTON_CONTENT_STYLE_TARGET_VECTORS,I as BUTTON_CONTENT_TEXT_VECTORS,h as BUTTON_ROW_ACTIVATABLE_VECTORS,g as BUTTON_ROW_ICON_VECTORS,L as BUTTON_STYLE_CLASS_VECTORS,R as CAROUSEL_CLAMP_VECTORS,z as CAROUSEL_NAVIGATE_VECTORS,B as CAROUSEL_PAGE_ALLOCATION_VECTORS,V as CAROUSEL_PAGE_AT_POSITION_VECTORS,H as CAROUSEL_PAGE_LIST_VECTORS,U as CAROUSEL_PROPERTY_DEFAULT_VECTORS,W as CAROUSEL_RANGE_VECTORS,G as CAROUSEL_REORDER_SHIFT_VECTORS,K as CAROUSEL_REVEAL_VECTORS,q as CAROUSEL_SIZES_FROM_SNAP_POINTS_VECTORS,J as CAROUSEL_SNAP_POINT_VECTORS,Y as CAROUSEL_WHEEL_LOCKOUT_VECTORS,X as CAROUSEL_WHEEL_VECTORS,Vt as CASE_FOLD_VECTORS,Q as CLAMP_ALLOCATE_VECTORS,$ as CLAMP_CHILD_SIZE_VECTORS,ee as CLAMP_PROPERTY_VECTORS,te as CLAMP_SIZE_FROM_CHILD_VECTORS,ne as CLAMP_THRESHOLD_VECTORS,Oe as COMBO_CHOOSER_VECTORS,ke as COMBO_SELECTION_VECTORS,a as CREDITS_SECTIONS_VECTORS,o as CREDIT_PERSON_VECTORS,le as DATA_GRID_CELL_TEXT_VECTORS,ue as DATA_GRID_COLUMN_CLASS_VECTORS,de as DATA_GRID_COLUMN_NORMALIZE_VECTORS,fe as DATA_GRID_INTERACTIVE_VECTORS,pe as DATA_GRID_TRACK_VECTORS,me as DATA_GRID_VARIANT_VECTORS,ve as ENTRY_MAX_LENGTH_VECTORS,ye as ENTRY_ROW_ACTIVATION_VECTORS,be as ENTRY_ROW_GUARD_VECTORS,xe as ENTRY_ROW_STATE_VECTORS,Se as ENTRY_TEXT_LENGTH_VECTORS,Ge as GLIB_CLAMP_VECTORS,Te as HEADER_BAR_PACK_VECTORS,Ee as HEADER_BAR_TITLE_SOURCE_VECTORS,De as HEADER_BAR_TITLE_WIDGET_VECTORS,gt as INLINE_TOGGLE_VECTORS,_t as INLINE_TOOLTIP_VECTORS,_ as LABEL_VISIBILITY_VECTORS,s as LEGAL_SECTION_VECTORS,c as LICENSE_INFO_VECTORS,l as LICENSE_SETTER_VECTORS,u as LICENSE_SPDX_VECTORS,d as LICENSE_TEXT_VECTORS,Ht as MAKE_COMPARABLE_VECTORS,st as MENU_BUTTON_DIRECTION_VECTORS,Ke as NATURAL_SIDEBAR_WIDTH_VECTORS,qe as NAVIGATION_ACTION_VECTORS,Je as NAVIGATION_SPLIT_VIEW_LAYOUT_VECTORS,Ye as NAVIGATION_STACK_VECTORS,Ne as NAVIGATION_VIEW_VECTORS,Xe as OVERLAY_COLLAPSE_VECTORS,Ze as OVERLAY_SPLIT_VIEW_LAYOUT_VECTORS,Qe as OVERLAY_SWIPE_AREA_VECTORS,$e as OVERLAY_SWIPE_CANCEL_VECTORS,et as OVERLAY_SWIPE_RELEASE_VECTORS,tt as OVERLAY_SWIPE_SNAP_POINT_VECTORS,nt as OVERLAY_SWIPE_START_VECTORS,Ce as PASSWORD_ENTRY_ROW_VECTORS,we as PASSWORD_REVEAL_GUARD_VECTORS,Zt as POPOVER_KEY_VECTORS,Qt as POPOVER_SURFACE_VECTORS,Ut as PREFERENCES_GROUP_HEADER_VECTORS,Wt as PREFERENCES_SEARCH_PAGES,Gt as PREFERENCES_SEARCH_VECTORS,Z as RADIO_GROUP_VECTORS,Kt as ROW_MATCH_VECTORS,qt as SEARCH_CORPUS_VECTORS,Jt as SEARCH_ROW_SUBTITLE_VECTORS,$t as SHORTCUT_LABEL_VECTORS,Le as SIDEBAR_ACTIVATION_VECTORS,rt as SIDEBAR_BOUNDS_VECTORS,Re as SIDEBAR_CLAMP_VECTORS,ze as SIDEBAR_FILTER_VECTORS,Be as SIDEBAR_ITEMS_CHANGED_VECTORS,Ve as SIDEBAR_ITEM_FLAG_VECTORS,He as SIDEBAR_MODEL_VECTORS,Ue as SIDEBAR_MODE_VECTORS,it as SIDEBAR_WIDTH_VECTORS,tn as SPINNER_ARC_ENVELOPE,nn as SPINNER_ARC_PHASE_VECTORS,rn as SPINNER_ARC_TOLERANCE,an as SPINNER_CONSTANT_VECTORS,re as SPINNER_GEOMETRY_VECTORS,ie as SPINNER_SIZE_VECTORS,ct as SPLIT_BUTTON_CONTENT_VECTORS,lt as SPLIT_BUTTON_DIRECTION_VECTORS,ut as SPLIT_BUTTON_DROPDOWN_VECTORS,dt as SPLIT_BUTTON_MENU_ACTIVATION_VECTORS,ft as SPLIT_BUTTON_MENU_PARSE_VECTORS,pt as SPLIT_BUTTON_ROOT_STATE_VECTORS,mt as SPLIT_BUTTON_STYLE_CLASS_VECTORS,ht as SPLIT_BUTTON_TOOLTIP_VECTORS,at as SPLIT_VIEW_MEASURE_VECTORS,Yt as STRIP_MARKUP_VECTORS,Xt as STRIP_MNEMONIC_VECTORS,v as SWITCH_ROW_NOTIFY_VECTORS,kt as TABS_REVEALED_VECTORS,At as TAB_CLOSE_VISIBLE_VECTORS,jt as TAB_DESCENDANT_VECTORS,Mt as TAB_ICON_STATE_VECTORS,Nt as TAB_PAGE_DESCRIPTOR_VECTORS,Pt as TAB_SUCCESSOR_VECTORS,Ft as TAB_TOOLTIP_VECTORS,It as TAB_VIEW_VECTORS,ot as TAGS_CONFLICT_VECTORS,ae as TOOLBAR_VIEW_ALLOCATE_VECTORS,oe as TOOLBAR_VIEW_CLASS_VECTORS,se as TOOLBAR_VIEW_CONTENT_FOR_SIZE_VECTORS,ce as TOOLBAR_VIEW_MEASURE_VECTORS,f as TRANSLATOR_CREDITS_VECTORS,Ae as VIEW_STACK_ICON_NAME_VECTORS,je as VIEW_STACK_PAGE_VECTORS,Me as VIEW_STACK_VECTORS,vt as VIEW_SWITCHER_BADGE_VECTORS,yt as VIEW_SWITCHER_BAR_REVEAL_VECTORS,bt as VIEW_SWITCHER_BAR_VECTORS,xt as VIEW_SWITCHER_BUTTON_VECTORS,St as VIEW_SWITCHER_BUTTON_VISIBILITY_VECTORS,Ct as VIEW_SWITCHER_DRAG_VECTORS,wt as VIEW_SWITCHER_ICON_VECTORS,Tt as VIEW_SWITCHER_MNEMONIC_VECTORS,Et as VIEW_SWITCHER_REBUILD_VECTORS,Dt as VIEW_SWITCHER_SELECTION_VECTORS,y as WINDOW_TITLE_VECTORS,on as WRAP_BOX_CHILD_ORDER_VECTORS,sn as WRAP_BOX_LENGTH_VECTORS,cn as WRAP_BOX_LINE_VECTORS,ln as WRAP_BOX_NATURAL_LENGTH_VECTORS,un as WRAP_BOX_NOTIFY_PROPERTIES,dn as WRAP_BOX_POLICY_VECTORS,fn as WRAP_BOX_SPACING_NOTIFY_VECTORS,pn as WRAP_BOX_SPACING_VECTORS,Lt as applyTabViewOp,Pe as collectNavigationState,Ot as createViewSwitcherClock,en as formatShortcutLabelNodes,Fe as navigationEventLog,_e as runBottomSheetSteps,Ie as runNavigationSteps,Rt as seedTabViewPages,zt as tabViewClosing,Bt as tabViewOrder};
1
+ import{ABOUT_DIALOG_CREDITS_LEGAL_VECTORS as e,ABOUT_DIALOG_DETAILS_VECTORS as t,ABOUT_DIALOG_HEADER_VECTORS as n,ABOUT_DIALOG_LABEL_VECTORS as r,ABOUT_DIALOG_SUPPORT_VECTORS as i,CREDITS_SECTIONS_VECTORS as a,CREDIT_PERSON_VECTORS as o,LEGAL_SECTION_VECTORS as s,LICENSE_INFO_VECTORS as c,LICENSE_SETTER_VECTORS as l,LICENSE_SPDX_VECTORS as u,LICENSE_TEXT_VECTORS as d,TRANSLATOR_CREDITS_VECTORS as f}from"./about-dialog.js";import{ACCENT_COLOR_VECTORS as p}from"./accent.js";import{ACTION_ROW_ACTIVATION_VECTORS as m,BUTTON_ROW_ACTIVATABLE_VECTORS as h,BUTTON_ROW_ICON_VECTORS as g,LABEL_VISIBILITY_VECTORS as _,SWITCH_ROW_NOTIFY_VECTORS as v,WINDOW_TITLE_VECTORS as y}from"./action-row.js";import{ADJUSTMENT_AUTHORED_VECTORS as b,ADJUSTMENT_PARSE_VECTORS as x,ADJUSTMENT_SNAP_VECTORS as S}from"./adjustment.js";import{AVATAR_COLOR_VECTORS as C,AVATAR_FONT_SIZE_VECTORS as w,AVATAR_INITIALS_VECTORS as T,AVATAR_MODE_VECTORS as E}from"./avatar.js";import{BANNER_BUTTON_STYLE_PARSE_VECTORS as D,BANNER_BUTTON_STYLE_VECTORS as O,BANNER_BUTTON_TEXT_VECTORS as k,BANNER_BUTTON_VISIBLE_VECTORS as A,BANNER_DEFAULT_VECTORS as j}from"./banner.js";import{BREAKPOINT_PICK_VECTORS as M,BREAKPOINT_TRANSITION_VECTORS as N}from"./breakpoint-bin.js";import{BUTTON_CONTENT_DEFAULT_VECTORS as P,BUTTON_CONTENT_ELLIPSIZE_VECTORS as F,BUTTON_CONTENT_ICON_VECTORS as I,BUTTON_CONTENT_LABEL_VECTORS as L,BUTTON_CONTENT_STYLE_TARGET_VECTORS as R,BUTTON_CONTENT_TEXT_VECTORS as z}from"./button-content.js";import{BUTTON_STYLE_CLASS_VECTORS as B}from"./button.js";import{CAROUSEL_CLAMP_VECTORS as V,CAROUSEL_NAVIGATE_VECTORS as H,CAROUSEL_PAGE_ALLOCATION_VECTORS as U,CAROUSEL_PAGE_AT_POSITION_VECTORS as W,CAROUSEL_PAGE_LIST_VECTORS as G,CAROUSEL_PROPERTY_DEFAULT_VECTORS as K,CAROUSEL_RANGE_VECTORS as q,CAROUSEL_REORDER_SHIFT_VECTORS as J,CAROUSEL_REVEAL_VECTORS as Y,CAROUSEL_SIZES_FROM_SNAP_POINTS_VECTORS as X,CAROUSEL_SNAP_POINT_VECTORS as Z,CAROUSEL_WHEEL_LOCKOUT_VECTORS as Q,CAROUSEL_WHEEL_VECTORS as $}from"./carousel.js";import{RADIO_GROUP_VECTORS as ee}from"./checks.js";import{CLAMP_ALLOCATE_VECTORS as te,CLAMP_CHILD_SIZE_VECTORS as ne,CLAMP_PROPERTY_VECTORS as re,CLAMP_SIZE_FROM_CHILD_VECTORS as ie,CLAMP_THRESHOLD_VECTORS as ae,SPINNER_GEOMETRY_VECTORS as oe,SPINNER_SIZE_VECTORS as se,TOOLBAR_VIEW_ALLOCATE_VECTORS as ce,TOOLBAR_VIEW_CLASS_VECTORS as le,TOOLBAR_VIEW_CONTENT_FOR_SIZE_VECTORS as ue,TOOLBAR_VIEW_MEASURE_VECTORS as de}from"./chrome.js";import{DATA_GRID_CELL_TEXT_VECTORS as fe,DATA_GRID_COLUMN_CLASS_VECTORS as pe,DATA_GRID_COLUMN_NORMALIZE_VECTORS as me,DATA_GRID_INTERACTIVE_VECTORS as he,DATA_GRID_TRACK_VECTORS as ge,DATA_GRID_VARIANT_VECTORS as _e}from"./data-grid.js";import{BOTTOM_SHEET_CLOSE_VECTORS as ve,BOTTOM_SHEET_PRESENTATION_VECTORS as ye,runBottomSheetSteps as be}from"./dialog.js";import{ENTRY_MAX_LENGTH_VECTORS as xe,ENTRY_ROW_ACTIVATION_VECTORS as Se,ENTRY_ROW_GUARD_VECTORS as Ce,ENTRY_ROW_STATE_VECTORS as we,ENTRY_TEXT_LENGTH_VECTORS as Te,PASSWORD_ENTRY_ROW_VECTORS as Ee,PASSWORD_REVEAL_GUARD_VECTORS as De}from"./entry-row.js";import{HEADER_BAR_PACK_VECTORS as Oe,HEADER_BAR_TITLE_SOURCE_VECTORS as ke,HEADER_BAR_TITLE_WIDGET_VECTORS as Ae}from"./header-bar.js";import{COMBO_CHOOSER_VECTORS as je,COMBO_SELECTION_VECTORS as Me}from"./rows.js";import{VIEW_STACK_ICON_NAME_VECTORS as Ne,VIEW_STACK_PAGE_VECTORS as Pe,VIEW_STACK_VECTORS as Fe}from"./view-stack.js";import{NAVIGATION_VIEW_VECTORS as Ie,collectNavigationState as Le,navigationEventLog as Re,runNavigationSteps as ze}from"./navigation-view.js";import{SIDEBAR_ACTIVATION_VECTORS as Be,SIDEBAR_CLAMP_VECTORS as Ve,SIDEBAR_FILTER_VECTORS as He,SIDEBAR_ITEMS_CHANGED_VECTORS as Ue,SIDEBAR_ITEM_FLAG_VECTORS as We,SIDEBAR_MODEL_VECTORS as Ge,SIDEBAR_MODE_VECTORS as Ke}from"./sidebar.js";import{ADW_LENGTH_UNIT_VECTORS as qe,GLIB_CLAMP_VECTORS as Je,NATURAL_SIDEBAR_WIDTH_VECTORS as Ye,NAVIGATION_ACTION_VECTORS as Xe,NAVIGATION_SPLIT_VIEW_LAYOUT_VECTORS as Ze,NAVIGATION_STACK_VECTORS as Qe,OVERLAY_COLLAPSE_VECTORS as $e,OVERLAY_SPLIT_VIEW_LAYOUT_VECTORS as et,OVERLAY_SWIPE_AREA_VECTORS as tt,OVERLAY_SWIPE_CANCEL_VECTORS as nt,OVERLAY_SWIPE_RELEASE_VECTORS as rt,OVERLAY_SWIPE_SNAP_POINT_VECTORS as it,OVERLAY_SWIPE_START_VECTORS as at,SIDEBAR_BOUNDS_VECTORS as ot,SIDEBAR_WIDTH_VECTORS as st,SPLIT_VIEW_MEASURE_VECTORS as ct,TAGS_CONFLICT_VECTORS as lt}from"./split-view.js";import{MENU_BUTTON_DIRECTION_VECTORS as ut,SPLIT_BUTTON_CONTENT_VECTORS as dt,SPLIT_BUTTON_DIRECTION_VECTORS as ft,SPLIT_BUTTON_DROPDOWN_VECTORS as pt,SPLIT_BUTTON_MENU_ACTIVATION_VECTORS as mt,SPLIT_BUTTON_ROOT_STATE_VECTORS as ht,SPLIT_BUTTON_STYLE_CLASS_VECTORS as gt,SPLIT_BUTTON_TOOLTIP_VECTORS as _t}from"./split-button.js";import{LIST_ITEMS_CHANGED_VECTORS as vt,LIST_MODEL_OWNERSHIP_VECTORS as yt,LIST_NORMALIZE_VECTORS as bt,LIST_PARSE_VECTORS as xt,LIST_SELECTION_CLAMP_VECTORS as St,TAB_PAGES_ITEMS_CHANGED_VECTORS as Ct,applyListReadback as wt,replayTabPagesAsSplices as Tt}from"./list.js";import{MENU_DETAILED_ACTION_VECTORS as Et,MENU_FLATTEN_VECTORS as Dt,MENU_ITEM_STATE_VECTORS as Ot,MENU_NORMALIZE_VECTORS as kt,MENU_PARSE_VECTORS as At,MENU_REFUSAL_VECTORS as jt}from"./menu.js";import{INLINE_TOGGLE_VECTORS as Mt,INLINE_TOOLTIP_VECTORS as Nt,VIEW_SWITCHER_BADGE_VECTORS as Pt,VIEW_SWITCHER_BAR_REVEAL_VECTORS as Ft,VIEW_SWITCHER_BAR_VECTORS as It,VIEW_SWITCHER_BUTTON_VECTORS as Lt,VIEW_SWITCHER_BUTTON_VISIBILITY_VECTORS as Rt,VIEW_SWITCHER_DRAG_VECTORS as zt,VIEW_SWITCHER_ICON_VECTORS as Bt,VIEW_SWITCHER_MNEMONIC_VECTORS as Vt,VIEW_SWITCHER_REBUILD_VECTORS as Ht,VIEW_SWITCHER_SELECTION_VECTORS as Ut,createViewSwitcherClock as Wt}from"./view-switcher.js";import{TABS_REVEALED_VECTORS as Gt,TAB_CLOSE_VISIBLE_VECTORS as Kt,TAB_DESCENDANT_VECTORS as qt,TAB_ICON_STATE_VECTORS as Jt,TAB_PAGE_DESCRIPTOR_VECTORS as Yt,TAB_SUCCESSOR_VECTORS as Xt,TAB_TOOLTIP_VECTORS as Zt,TAB_VIEW_VECTORS as Qt,applyTabViewOp as $t,seedTabViewPages as en,tabViewClosing as tn,tabViewOrder as nn}from"./tab-view.js";import{CASE_FOLD_VECTORS as rn,MAKE_COMPARABLE_VECTORS as an,PREFERENCES_GROUP_HEADER_VECTORS as on,PREFERENCES_SEARCH_PAGES as sn,PREFERENCES_SEARCH_VECTORS as cn,ROW_MATCH_VECTORS as ln,SEARCH_CORPUS_VECTORS as un,SEARCH_ROW_SUBTITLE_VECTORS as dn,STRIP_MARKUP_VECTORS as fn,STRIP_MNEMONIC_VECTORS as pn}from"./preferences.js";import{POPOVER_KEY_VECTORS as mn,POPOVER_SURFACE_VECTORS as hn}from"./popover.js";import{SHORTCUT_LABEL_VECTORS as gn,formatShortcutLabelNodes as _n}from"./shortcut-label.js";import{SPINNER_ARC_ENVELOPE as vn,SPINNER_ARC_PHASE_VECTORS as yn,SPINNER_ARC_TOLERANCE as bn,SPINNER_CONSTANT_VECTORS as xn}from"./spinner.js";import{WRAP_BOX_CHILD_ORDER_VECTORS as Sn,WRAP_BOX_LENGTH_VECTORS as Cn,WRAP_BOX_LINE_VECTORS as wn,WRAP_BOX_NATURAL_LENGTH_VECTORS as Tn,WRAP_BOX_NOTIFY_PROPERTIES as En,WRAP_BOX_POLICY_VECTORS as Dn,WRAP_BOX_SPACING_NOTIFY_VECTORS as On,WRAP_BOX_SPACING_VECTORS as kn}from"./wrap-box.js";export{e as ABOUT_DIALOG_CREDITS_LEGAL_VECTORS,t as ABOUT_DIALOG_DETAILS_VECTORS,n as ABOUT_DIALOG_HEADER_VECTORS,r as ABOUT_DIALOG_LABEL_VECTORS,i as ABOUT_DIALOG_SUPPORT_VECTORS,p as ACCENT_COLOR_VECTORS,m as ACTION_ROW_ACTIVATION_VECTORS,b as ADJUSTMENT_AUTHORED_VECTORS,x as ADJUSTMENT_PARSE_VECTORS,S as ADJUSTMENT_SNAP_VECTORS,qe as ADW_LENGTH_UNIT_VECTORS,C as AVATAR_COLOR_VECTORS,w as AVATAR_FONT_SIZE_VECTORS,T as AVATAR_INITIALS_VECTORS,E as AVATAR_MODE_VECTORS,D as BANNER_BUTTON_STYLE_PARSE_VECTORS,O as BANNER_BUTTON_STYLE_VECTORS,k as BANNER_BUTTON_TEXT_VECTORS,A as BANNER_BUTTON_VISIBLE_VECTORS,j as BANNER_DEFAULT_VECTORS,ve as BOTTOM_SHEET_CLOSE_VECTORS,ye as BOTTOM_SHEET_PRESENTATION_VECTORS,M as BREAKPOINT_PICK_VECTORS,N as BREAKPOINT_TRANSITION_VECTORS,P as BUTTON_CONTENT_DEFAULT_VECTORS,F as BUTTON_CONTENT_ELLIPSIZE_VECTORS,I as BUTTON_CONTENT_ICON_VECTORS,L as BUTTON_CONTENT_LABEL_VECTORS,R as BUTTON_CONTENT_STYLE_TARGET_VECTORS,z as BUTTON_CONTENT_TEXT_VECTORS,h as BUTTON_ROW_ACTIVATABLE_VECTORS,g as BUTTON_ROW_ICON_VECTORS,B as BUTTON_STYLE_CLASS_VECTORS,V as CAROUSEL_CLAMP_VECTORS,H as CAROUSEL_NAVIGATE_VECTORS,U as CAROUSEL_PAGE_ALLOCATION_VECTORS,W as CAROUSEL_PAGE_AT_POSITION_VECTORS,G as CAROUSEL_PAGE_LIST_VECTORS,K as CAROUSEL_PROPERTY_DEFAULT_VECTORS,q as CAROUSEL_RANGE_VECTORS,J as CAROUSEL_REORDER_SHIFT_VECTORS,Y as CAROUSEL_REVEAL_VECTORS,X as CAROUSEL_SIZES_FROM_SNAP_POINTS_VECTORS,Z as CAROUSEL_SNAP_POINT_VECTORS,Q as CAROUSEL_WHEEL_LOCKOUT_VECTORS,$ as CAROUSEL_WHEEL_VECTORS,rn as CASE_FOLD_VECTORS,te as CLAMP_ALLOCATE_VECTORS,ne as CLAMP_CHILD_SIZE_VECTORS,re as CLAMP_PROPERTY_VECTORS,ie as CLAMP_SIZE_FROM_CHILD_VECTORS,ae as CLAMP_THRESHOLD_VECTORS,je as COMBO_CHOOSER_VECTORS,Me as COMBO_SELECTION_VECTORS,a as CREDITS_SECTIONS_VECTORS,o as CREDIT_PERSON_VECTORS,fe as DATA_GRID_CELL_TEXT_VECTORS,pe as DATA_GRID_COLUMN_CLASS_VECTORS,me as DATA_GRID_COLUMN_NORMALIZE_VECTORS,he as DATA_GRID_INTERACTIVE_VECTORS,ge as DATA_GRID_TRACK_VECTORS,_e as DATA_GRID_VARIANT_VECTORS,xe as ENTRY_MAX_LENGTH_VECTORS,Se as ENTRY_ROW_ACTIVATION_VECTORS,Ce as ENTRY_ROW_GUARD_VECTORS,we as ENTRY_ROW_STATE_VECTORS,Te as ENTRY_TEXT_LENGTH_VECTORS,Je as GLIB_CLAMP_VECTORS,Oe as HEADER_BAR_PACK_VECTORS,ke as HEADER_BAR_TITLE_SOURCE_VECTORS,Ae as HEADER_BAR_TITLE_WIDGET_VECTORS,Mt as INLINE_TOGGLE_VECTORS,Nt as INLINE_TOOLTIP_VECTORS,_ as LABEL_VISIBILITY_VECTORS,s as LEGAL_SECTION_VECTORS,c as LICENSE_INFO_VECTORS,l as LICENSE_SETTER_VECTORS,u as LICENSE_SPDX_VECTORS,d as LICENSE_TEXT_VECTORS,vt as LIST_ITEMS_CHANGED_VECTORS,yt as LIST_MODEL_OWNERSHIP_VECTORS,bt as LIST_NORMALIZE_VECTORS,xt as LIST_PARSE_VECTORS,St as LIST_SELECTION_CLAMP_VECTORS,an as MAKE_COMPARABLE_VECTORS,ut as MENU_BUTTON_DIRECTION_VECTORS,Et as MENU_DETAILED_ACTION_VECTORS,Dt as MENU_FLATTEN_VECTORS,Ot as MENU_ITEM_STATE_VECTORS,kt as MENU_NORMALIZE_VECTORS,At as MENU_PARSE_VECTORS,jt as MENU_REFUSAL_VECTORS,Ye as NATURAL_SIDEBAR_WIDTH_VECTORS,Xe as NAVIGATION_ACTION_VECTORS,Ze as NAVIGATION_SPLIT_VIEW_LAYOUT_VECTORS,Qe as NAVIGATION_STACK_VECTORS,Ie as NAVIGATION_VIEW_VECTORS,$e as OVERLAY_COLLAPSE_VECTORS,et as OVERLAY_SPLIT_VIEW_LAYOUT_VECTORS,tt as OVERLAY_SWIPE_AREA_VECTORS,nt as OVERLAY_SWIPE_CANCEL_VECTORS,rt as OVERLAY_SWIPE_RELEASE_VECTORS,it as OVERLAY_SWIPE_SNAP_POINT_VECTORS,at as OVERLAY_SWIPE_START_VECTORS,Ee as PASSWORD_ENTRY_ROW_VECTORS,De as PASSWORD_REVEAL_GUARD_VECTORS,mn as POPOVER_KEY_VECTORS,hn as POPOVER_SURFACE_VECTORS,on as PREFERENCES_GROUP_HEADER_VECTORS,sn as PREFERENCES_SEARCH_PAGES,cn as PREFERENCES_SEARCH_VECTORS,ee as RADIO_GROUP_VECTORS,ln as ROW_MATCH_VECTORS,un as SEARCH_CORPUS_VECTORS,dn as SEARCH_ROW_SUBTITLE_VECTORS,gn as SHORTCUT_LABEL_VECTORS,Be as SIDEBAR_ACTIVATION_VECTORS,ot as SIDEBAR_BOUNDS_VECTORS,Ve as SIDEBAR_CLAMP_VECTORS,He as SIDEBAR_FILTER_VECTORS,Ue as SIDEBAR_ITEMS_CHANGED_VECTORS,We as SIDEBAR_ITEM_FLAG_VECTORS,Ge as SIDEBAR_MODEL_VECTORS,Ke as SIDEBAR_MODE_VECTORS,st as SIDEBAR_WIDTH_VECTORS,vn as SPINNER_ARC_ENVELOPE,yn as SPINNER_ARC_PHASE_VECTORS,bn as SPINNER_ARC_TOLERANCE,xn as SPINNER_CONSTANT_VECTORS,oe as SPINNER_GEOMETRY_VECTORS,se as SPINNER_SIZE_VECTORS,dt as SPLIT_BUTTON_CONTENT_VECTORS,ft as SPLIT_BUTTON_DIRECTION_VECTORS,pt as SPLIT_BUTTON_DROPDOWN_VECTORS,mt as SPLIT_BUTTON_MENU_ACTIVATION_VECTORS,ht as SPLIT_BUTTON_ROOT_STATE_VECTORS,gt as SPLIT_BUTTON_STYLE_CLASS_VECTORS,_t as SPLIT_BUTTON_TOOLTIP_VECTORS,ct as SPLIT_VIEW_MEASURE_VECTORS,fn as STRIP_MARKUP_VECTORS,pn as STRIP_MNEMONIC_VECTORS,v as SWITCH_ROW_NOTIFY_VECTORS,Gt as TABS_REVEALED_VECTORS,Kt as TAB_CLOSE_VISIBLE_VECTORS,qt as TAB_DESCENDANT_VECTORS,Jt as TAB_ICON_STATE_VECTORS,Ct as TAB_PAGES_ITEMS_CHANGED_VECTORS,Yt as TAB_PAGE_DESCRIPTOR_VECTORS,Xt as TAB_SUCCESSOR_VECTORS,Zt as TAB_TOOLTIP_VECTORS,Qt as TAB_VIEW_VECTORS,lt as TAGS_CONFLICT_VECTORS,ce as TOOLBAR_VIEW_ALLOCATE_VECTORS,le as TOOLBAR_VIEW_CLASS_VECTORS,ue as TOOLBAR_VIEW_CONTENT_FOR_SIZE_VECTORS,de as TOOLBAR_VIEW_MEASURE_VECTORS,f as TRANSLATOR_CREDITS_VECTORS,Ne as VIEW_STACK_ICON_NAME_VECTORS,Pe as VIEW_STACK_PAGE_VECTORS,Fe as VIEW_STACK_VECTORS,Pt as VIEW_SWITCHER_BADGE_VECTORS,Ft as VIEW_SWITCHER_BAR_REVEAL_VECTORS,It as VIEW_SWITCHER_BAR_VECTORS,Lt as VIEW_SWITCHER_BUTTON_VECTORS,Rt as VIEW_SWITCHER_BUTTON_VISIBILITY_VECTORS,zt as VIEW_SWITCHER_DRAG_VECTORS,Bt as VIEW_SWITCHER_ICON_VECTORS,Vt as VIEW_SWITCHER_MNEMONIC_VECTORS,Ht as VIEW_SWITCHER_REBUILD_VECTORS,Ut as VIEW_SWITCHER_SELECTION_VECTORS,y as WINDOW_TITLE_VECTORS,Sn as WRAP_BOX_CHILD_ORDER_VECTORS,Cn as WRAP_BOX_LENGTH_VECTORS,wn as WRAP_BOX_LINE_VECTORS,Tn as WRAP_BOX_NATURAL_LENGTH_VECTORS,En as WRAP_BOX_NOTIFY_PROPERTIES,Dn as WRAP_BOX_POLICY_VECTORS,On as WRAP_BOX_SPACING_NOTIFY_VECTORS,kn as WRAP_BOX_SPACING_VECTORS,wt as applyListReadback,$t as applyTabViewOp,Le as collectNavigationState,Wt as createViewSwitcherClock,_n as formatShortcutLabelNodes,Re as navigationEventLog,Tt as replayTabPagesAsSplices,be as runBottomSheetSteps,ze as runNavigationSteps,en as seedTabViewPages,tn as tabViewClosing,nn as tabViewOrder};
@@ -0,0 +1 @@
1
+ import"../_virtual/_rolldown/runtime.js";import{tabViewItemsChanged as e}from"../tab-view.js";const t=[{input:[`Cyan`,`Magenta`],model:[{value:`Cyan`,label:`Cyan`},{value:`Magenta`,label:`Magenta`}],rule:"a bare string is both value and label — `Gtk.StringList`, which is what a combo row is fed in the common case"},{input:[{value:`a`,label:`One`}],model:[{value:`a`,label:`One`}],rule:`a full descriptor passes through unchanged`},{input:[{label:`Apple`}],model:[{value:`Apple`,label:`Apple`}],rule:"a label with no value is addressable BY that label — otherwise the item answers to `undefined` and `selectedValue` can never reach it"},{input:[{value:`k`}],model:[{value:`k`,label:`k`}],rule:`a value with no label draws its value, so an item is never blank by omission`},{input:[{value:7,label:42}],model:[{value:`7`,label:`42`}],rule:`both halves are stringified: the model is a string list on GTK, and a number that stayed a number would fail an === against the attribute it round-trips through`},{input:[{value:``,label:`blank`}],model:[{value:``,label:`blank`}],rule:`an EMPTY value is a value — it is not missing, so the label does not stand in for it`},{input:[],model:[],rule:`the empty model normalises to the empty model, which is the state a placeholder is drawn from`}],n=[{attribute:`["a","b"]`,model:[{value:`a`,label:`a`},{value:`b`,label:`b`}],rule:`the string-array form, which is what markup writes in the common case`},{attribute:`[{"value":"a","label":"A"}]`,model:[{value:`a`,label:`A`}],rule:`the descriptor form`},{attribute:`[not json`,model:[],rule:`unparseable JSON is an author slip and yields the empty model — it must not stop the element upgrading`},{attribute:`{"a":1}`,model:[],rule:"well-formed JSON that is not an ARRAY is the second, different slip, and it answers the same way rather than throwing on `.map`"},{attribute:``,model:[],rule:`an empty attribute is an empty model, not a parse attempt`}],r={value:`a`,label:`A`},i={value:`b`,label:`B`},a={value:`c`,label:`C`},o=[r,i,a],s=[{previous:[],next:o,change:{position:0,removed:0,added:3},survivors:0,rule:`the first assignment adds everything at 0 — there is nothing to carry over`},{previous:o,next:[...o,{value:`d`,label:`D`}],change:{position:3,removed:0,added:1},survivors:3,rule:`an APPEND touches one position: three views stand, and this is the row a rebuild fails while the model still reads correct`},{previous:o,next:[{value:`z`,label:`Z`},...o],change:{position:0,removed:0,added:1},survivors:3,rule:`a PREPEND is one insertion at 0, not a shift of everything after it — positions move, nodes do not`},{previous:o,next:[r,a],change:{position:1,removed:1,added:0},survivors:2,rule:`a removal from the middle: the shared suffix is what keeps it one item wide`},{previous:o,next:[r,{value:`b`,label:`Renamed`},a],change:{position:1,removed:1,added:1},survivors:2,rule:"a RELABELLED item at an unchanged value is inside the range — comparing by value alone would leave the old text on screen, which is what `selection_item_changed` exists for upstream"},{previous:o,next:o,change:null,survivors:3,rule:`an equal model emits NOTHING, as GTK does — a renderer that rebuilt here would discard three live views for no change at all`},{previous:o,next:[{value:`a`,label:`A`},{value:`b`,label:`B`},{value:`c`,label:`C`}],change:null,survivors:3,rule:`equality is STRUCTURAL, not by array identity: a caller that rebuilds its array every render must not force a rebuild here`},{previous:o,next:[],change:{position:0,removed:3,added:0},survivors:0,rule:`emptying the model removes everything from 0`},{previous:o,next:[a,i,r],change:{position:0,removed:3,added:3},survivors:0,rule:"a REVERSAL is the whole span: `items-changed` has no vocabulary for a move, and neither does `g_list_store_move`, which reports one the same way"}],c=[{initial:[r,i],source:`readback`,op:`append`,assign:!1,model:[r,i],itemsChanged:null,survivors:2,rule:`a model read back is the CALLER's array — pushing onto it moves nothing, because nothing was assigned`},{initial:[r,i],source:`readback`,op:`append`,assign:!0,model:[r,i,{value:`z`,label:`Z`}],itemsChanged:{position:2,removed:0,added:1},survivors:2,rule:`read, push, assign is one insertion at the end — the pattern a full rebuild used to serve and a splice over a shared array answers with nothing at all`},{initial:[r,i],source:`readback`,op:`relabel-first`,assign:!0,model:[{value:`a`,label:`Renamed`},i],itemsChanged:{position:0,removed:1,added:1},survivors:1,rule:`relabelling an item THROUGH the array read back is the same failure one level down: a shared descriptor changes the stored model too, so the comparison sees no change`},{initial:[r,i,a],source:`readback`,op:`remove-first`,assign:!0,model:[i,a],itemsChanged:{position:0,removed:1,added:0},survivors:2,rule:`the shrink direction, which a shared array reports as a model that got shorter on BOTH sides and therefore did not change`},{initial:[r,i],source:`input`,op:`append`,assign:!0,model:[r,i,{value:`z`,label:`Z`}],itemsChanged:{position:2,removed:0,added:1},survivors:2,rule:`the OTHER door — an array the caller ASSIGNED and kept a reference to. Closing only the read-back one leaves the same comparison reading the new value on both sides, by the other route`}];function applyListReadback(e,t){if(t===`append`)e.push({value:`z`,label:`Z`});else if(t===`relabel-first`){let t=e[0];t&&(t.label=`Renamed`)}else e.shift();return e}const l=[{selected:1,length:3,result:1,rule:`a position the new model has is kept`},{selected:5,length:3,result:0,rule:"a position past the end falls back to 0 — `GtkSingleSelection` autoselects rather than deselecting"},{selected:-1,length:3,result:0,rule:"the SENTINEL falls back to 0 too, which is how a widget recovers a selection when its model grows; a one-sided `selected >= length` would leave the -1 standing"},{selected:0,length:0,result:-1,rule:`an EMPTY model has no 0 to fall back to, so it lands on the sentinel and a placeholder becomes drawable`},{selected:NaN,length:3,result:0,rule:"a non-finite position addresses no item — the same answer as one past the end, so a `parseInt` of a malformed attribute cannot poison the index"}],u=[{change:{kind:`attached`,id:`C`,position:2,previousPosition:-1},itemsChanged:{position:2,removed:0,added:1},before:[`A`,`B`],after:[`A`,`B`,`C`],rule:"attached is one addition at the new position; `previousPosition` is -1 because the page had none"},{change:{kind:`detached`,id:`B`,position:1,previousPosition:1},itemsChanged:{position:1,removed:1,added:0},before:[`A`,`B`,`C`],after:[`A`,`C`],rule:`detached is one removal at the position it was removed FROM`},{change:{kind:`updated`,id:`B`,position:1,previousPosition:1},itemsChanged:{position:1,removed:1,added:1},before:[`A`,`B`,`C`],after:[`A`,`B`,`C`],rule:'a per-page notify is removed-1/added-1 at that position — `GListModel` has no other verb for "this item is different now" — and it moves nothing'},{change:{kind:`reordered`,id:`D`,position:1,previousPosition:3},itemsChanged:{position:1,removed:3,added:3},before:[`A`,`B`,`C`,`D`],after:[`A`,`D`,`B`,`C`],rule:`a move BACKWARDS is the span between the two positions, re-added in the new order`},{change:{kind:`reordered`,id:`A`,position:2,previousPosition:0},itemsChanged:{position:0,removed:3,added:3},before:[`A`,`B`,`C`,`D`],after:[`B`,`C`,`A`,`D`],rule:`a move FORWARDS spans the same way — the position is the LOWER of the two, so the range covers both ends`},{change:{kind:`pinned`,id:`C`,position:0,previousPosition:2},itemsChanged:{position:0,removed:3,added:3},before:[`A`,`B`,`C`],after:[`C`,`A`,`B`],rule:`pinning is a flip AND a re-order, so it reports as the move it is rather than as an update in place`}];function replayTabPagesAsSplices(t,n){let r=[...t];for(let t of n){let{position:n,removed:i,added:a}=e(t),o=r.splice(n,i);if(a===0)continue;if(t.kind===`attached`){r.splice(n,0,t.id);continue}if(t.kind===`updated`){r.splice(n,0,...o);continue}let s=o.filter(e=>e!==t.id);s.splice(t.position-n,0,t.id),r.splice(n,0,...s)}return r}export{s as LIST_ITEMS_CHANGED_VECTORS,c as LIST_MODEL_OWNERSHIP_VECTORS,t as LIST_NORMALIZE_VECTORS,n as LIST_PARSE_VECTORS,l as LIST_SELECTION_CLAMP_VECTORS,u as TAB_PAGES_ITEMS_CHANGED_VECTORS,applyListReadback,replayTabPagesAsSplices};
@@ -0,0 +1 @@
1
+ const e=[{input:[`Save as…`],model:[{kind:`item`,label:`Save as…`}],rule:`a bare string is a label-only item — the shorthand NativeScript used to be alone in having`},{input:[{label:`Save as…`,action:`app.save-as`}],model:[{kind:`item`,label:`Save as…`,action:`app.save-as`}],rule:`the GTK shape: (label, detailed action) pairs (gtkpopovermenu.c:101,103)`},{input:[{section:[{label:`Cut`,action:`app.cut`},`Copy`],label:`Edit`}],model:[{kind:`section`,items:[{kind:`item`,label:`Cut`,action:`app.cut`},{kind:`item`,label:`Copy`}],label:`Edit`}],rule:"a `section` key IS the section link, and its `label` is the group heading (gtkpopovermenu.c:115-117)"},{input:[{label:`More`,submenu:[`Rename`],icon:`view-more-symbolic`}],model:[{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Rename`}],icon:`view-more-symbolic`}],rule:"a `submenu` key wins over the attributes beside it — a link is read before an attribute (gtkpopovermenu.c:126-131)"},{input:[{label:`Recent`,submenu:[`Report.pdf`],submenuAction:`win.recent-shown`,macosSpecial:`services`}],model:[{kind:`submenu`,label:`Recent`,items:[{kind:`item`,label:`Report.pdf`}],submenuAction:`win.recent-shown`,macosSpecial:`services`}],rule:"the two submenu attributes the first cut dropped in silence — `submenu-action` (gtkpopovermenu.c:106-107, read at gtkmenutrackeritem.c:822) and `gtk-macos-special` (:130-131, read at :761)"},{input:[{label:`List`,action:`app.view::list`}],model:[{kind:`item`,label:`List`,action:`app.view::list`}],rule:`the target travels INSIDE the detailed action, so no GVariant encoding has to be invented`},{input:[{label:`Zoom`,custom:`zoom-control`}],model:[{kind:`item`,label:`Zoom`,custom:`zoom-control`}],rule:"`custom` names an application widget and survives normalisation — refusing it is a SURFACE question"},{input:[{label:`Undo`,accel:`<Control>z`,verbIcon:`edit-undo-symbolic`,useMarkup:!0}],model:[{kind:`item`,label:`Undo`,verbIcon:`edit-undo-symbolic`,accel:`<Control>z`,useMarkup:!0}],rule:`the decoration attributes round-trip whether or not a given surface draws them`},{input:[{label:`Delete`,hiddenWhen:`action-disabled`},{label:`X`,hiddenWhen:`whenever`}],model:[{kind:`item`,label:`Delete`,hiddenWhen:`action-disabled`},{kind:`item`,label:`X`}],rule:'an unknown `hidden-when` is IGNORED, not stored: "Ignore other values" (gtkmenutrackeritem.c:530-535 + the comment at :537-544)'},{input:[{label:`Open`,action:7,icon:{name:`x`}}],model:[{kind:`item`,label:`Open`}],rule:`a non-string attribute is dropped rather than leaked into a field typed as one`},{input:[{label:`Open`,action:``}],model:[{kind:`item`,label:`Open`}],rule:"an EMPTY action is not an action — GIO refuses `''`, and dropping it here is one abort the GTK path never has to refuse"},{input:[{},null,42,[`nested`],{label:42}],model:[],rule:`an entry with no usable attribute and no link draws nothing, so it is not an entry`},{input:[{label:``}],model:[{kind:`item`,label:``}],rule:"an EMPTY label is a label — the same distinction `text-button` is keyed off"},{input:[{kind:`section`,items:[{kind:`item`,label:`Cut`}]},{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Rename`}]}],model:[{kind:`section`,items:[{kind:`item`,label:`Cut`}]},{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Rename`}]}],rule:`IDEMPOTENCE: a normalised model is legal input, or handing a widget its own model back would flatten it`}],t=[{json:`[{"label":"Save as…","action":"app.save-as"}]`,model:[{kind:`item`,label:`Save as…`,action:`app.save-as`}],rule:`the GTK shape through the attribute door`},{json:`[{"label":"Copy","action":"app.copy"},{"label":"Copy","action":"app.copy-special"}]`,model:[{kind:`item`,label:`Copy`,action:`app.copy`},{kind:`item`,label:`Copy`,action:`app.copy-special`}],rule:`duplicate labels are legal and must NOT collapse`},{json:`[{"label":"About","id":"about","icon":"help-about-symbolic"}]`,model:[{kind:`item`,label:`About`,icon:`help-about-symbolic`,id:`about`}],rule:`the menu-button extras (id/icon) are attributes like any other`},{json:`[{"section":[{"label":"Cut"}]},{"label":"More","submenu":[{"label":"Rename"}]}]`,model:[{kind:`section`,items:[{kind:`item`,label:`Cut`}]},{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Rename`}]}],rule:`sections and submenus are writable in markup — the whole point of a JSON attribute`},{json:null,model:[],rule:`no attribute → no menu`},{json:``,model:[],rule:`an empty attribute → no menu`},{json:`not json at all`,model:[],rule:`malformed JSON degrades to no menu, it does not throw`},{json:`{"label":"Save"}`,model:[],rule:`a non-array root is rejected wholesale`},{json:`[]`,model:[],rule:`an empty array is an empty menu`},{json:`[{"action":"app.x"},null,42,["label"]]`,model:[{kind:`item`,label:``,action:`app.x`}],rule:`an entry with an action but no label is still an item; the three junk entries are not`}],n=[{model:[{kind:`item`,label:`New`},{kind:`section`,items:[{kind:`item`,label:`Cut`},{kind:`item`,label:`Copy`}]},{kind:`item`,label:`Quit`}],rows:[{label:`New`,path:[0],separated:!1},{label:`Cut`,path:[1,0],separated:!0},{label:`Copy`,path:[1,1],separated:!1},{label:`Quit`,path:[2],separated:!0}],rule:`a section is inlined and separated on BOTH sides; its items keep their real paths`},{model:[{kind:`section`,items:[{kind:`item`,label:`Cut`}]},{kind:`item`,label:`Quit`}],rows:[{label:`Cut`,path:[0,0],separated:!1},{label:`Quit`,path:[1],separated:!0}],rule:`a LEADING section draws no separator above it`},{model:[{kind:`section`,items:[{kind:`item`,label:`A`}]},{kind:`section`,items:[{kind:`item`,label:`B`}]}],rows:[{label:`A`,path:[0,0],separated:!1},{label:`B`,path:[1,0],separated:!0}],rule:`two adjacent sections are separated once, not twice`},{model:[{kind:`section`,items:[]},{kind:`item`,label:`Quit`}],rows:[{label:`Quit`,path:[1],separated:!1}],rule:`an EMPTY section draws nothing and opens no boundary — a separator with no group above it`},{model:[{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Rename`}]}],rows:[{label:`More`,path:[0],separated:!1}],rule:`a submenu stays ONE row: inlining it would offer items the user never opened`}],r=[{detailed:`app.save-as`,name:`app.save-as`,gioValid:!0,rule:`no target`},{detailed:`app.view::list`,name:`app.view`,target:`list`,gioValid:!0,rule:"the `::` form — a string target"},{detailed:`win.zoom(2)`,name:`win.zoom`,target:`2`,gioValid:!0,rule:"the `(…)` form — a GVariant text target"},{detailed:`app.view('list')`,name:`app.view`,target:`list`,gioValid:!0,rule:"the QUOTED `(…)` form is the same target as the `::` form — unquoted, or a radio written this way reads OFF"},{detailed:`app.view('a\\'b')`,name:`app.view`,target:`a'b`,gioValid:!0,rule:`GVariant text ESCAPES the quote inside a quoted string; leaving the escape on is wrong CONTENT, not a second spelling`},{detailed:`app.view('a\\\\b')`,name:`app.view`,target:`a\\b`,gioValid:!0,rule:`and the backslash — the only other character GVariant escapes there`},{detailed:`app.view::a::b`,name:`app.view`,target:`a::b`,gioValid:!0,rule:"only the FIRST `::` splits; the rest is target text"},{detailed:`app.x(`,name:`app.x(`,gioValid:!1,rule:"an unterminated `(` is not the target form — the splitter keeps the lot, GIO ABORTS on it"},{detailed:`win.zoom(qqq)`,name:`win.zoom`,target:`qqq`,gioValid:!1,rule:"the splitter cannot know `qqq` is not a GVariant; GIO can, and aborts"},{detailed:`app.a b`,name:`app.a b`,gioValid:!1,rule:`a space is not legal in an action name`},{detailed:`app.x)`,name:`app.x)`,gioValid:!1,rule:"a stray `)` is not the target form"},{detailed:`app.x()`,name:`app.x`,target:``,gioValid:!1,rule:`an EMPTY target is not a GVariant — "0:expected value"`},{detailed:`a.b(1,2)`,name:`a.b`,target:`1,2`,gioValid:!1,rule:`two values are not one target — "1:expected end of input"`}],i={"app.sidebar":{state:`true`},"app.view":{state:`list`},"app.save":{enabled:!1},"app.copy":{}},a=[{item:{kind:`item`,label:`Heading`},actions:i,state:{sensitive:!0,toggled:!1,role:`normal`,visible:!0},rule:`NO action at all is SENSITIVE — C sets it explicitly in the else branch (c:591-595, the assignment at c:594)`},{item:{kind:`item`,label:`Save`,action:`app.save`},actions:i,state:{sensitive:!1,toggled:!1,role:`normal`,visible:!0},rule:"sensitive IS the action’s enabled flag — `self->sensitive = enabled` (c:332)"},{item:{kind:`item`,label:`Copy`,action:`app.copy`},actions:i,state:{sensitive:!0,toggled:!1,role:`normal`,visible:!0},rule:`an action with no state is a plain command`},{item:{kind:`item`,label:`Missing`,action:`app.nope`},actions:i,state:{sensitive:!1,toggled:!1,role:`normal`,visible:!0},rule:`an action the group has not got is INSENSITIVE, and still shown (c:582-586)`},{item:{kind:`item`,label:`Sidebar`,action:`app.sidebar`},actions:i,state:{sensitive:!0,toggled:!0,role:`check`,visible:!0},rule:`a boolean state with no target is a CHECK, toggled by the state (c:342-346)`},{item:{kind:`item`,label:`List`,action:`app.view::list`},actions:i,state:{sensitive:!0,toggled:!0,role:`radio`,visible:!0},rule:`a target AND a state is a RADIO, toggled when they are equal (c:336-340)`},{item:{kind:`item`,label:`Grid`,action:`app.view::grid`},actions:i,state:{sensitive:!0,toggled:!1,role:`radio`,visible:!0},rule:`the OTHER radio of the same action is a radio too, and off`},{item:{kind:`item`,label:`Save`,action:`app.save`,hiddenWhen:`action-disabled`},actions:i,state:{sensitive:!1,toggled:!1,role:`normal`,visible:!1},rule:`hidden-when="action-disabled" folds onto sensitive (c:271-272)`},{item:{kind:`item`,label:`Ghost`,action:`app.nope`,hiddenWhen:`action-missing`},actions:i,state:{sensitive:!1,toggled:!1,role:`normal`,visible:!1},rule:`hidden-when="action-missing" folds onto can_activate (c:267-268)`},{item:{kind:`item`,label:`Ghost`,hiddenWhen:`action-missing`},actions:i,state:{sensitive:!0,toggled:!1,role:`normal`,visible:!1},rule:`an actionless item with hidden-when="action-missing" is hidden FOR EVER — C says so in its own comment (c:541-543)`},{item:{kind:`item`,label:`Quit`,action:`app.quit`},actions:{},state:{sensitive:!1,toggled:!1,role:`normal`,visible:!0},rule:`an EMPTY group knows the action is missing, so the item is insensitive`},{item:{kind:`item`,label:`Menubar`,action:`app.copy`,hiddenWhen:`macos-menubar`},actions:i,state:{sensitive:!0,toggled:!1,role:`normal`,visible:!0},rule:"macos-menubar hides only under `mac_os_mode`, which no renderer here is (c:534-535)"}],o=[{model:[{kind:`item`,label:`Save`,action:`app.save`}],paths:[],rule:`an ordinary menu is refused by nothing`},{model:[{kind:`item`,label:`Zoom`,custom:`zoom-control`}],paths:[[0]],rule:"`custom` names an application widget, so a blank row would be the alternative"},{model:[{kind:`item`,label:`A`},{kind:`section`,items:[{kind:`item`,label:`Z`,custom:`zoom`}]},{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`C`,custom:`colour`}]}],paths:[[1,0],[2,0]],rule:`the walk enters sections AND submenus — a refusal three levels down is still a blank row`},{model:[{kind:`item`,label:`A`,custom:`one`},{kind:`item`,label:`B`,custom:`two`}],paths:[[0],[1]],rule:`EVERY refusal is reported, not the first: a GTK menu typically has all of its custom items at once`}];export{r as MENU_DETAILED_ACTION_VECTORS,n as MENU_FLATTEN_VECTORS,a as MENU_ITEM_STATE_VECTORS,e as MENU_NORMALIZE_VECTORS,t as MENU_PARSE_VECTORS,o as MENU_REFUSAL_VECTORS};
@@ -1 +1 @@
1
- const e=[{label:`One`,value:`a`},{label:`Two`,value:`b`}],t=[{name:`programmatic index set`,steps:[{op:`setOptions`,options:e},{op:`setSelectedIndex`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:"a changed position reaches the selection, whose notify becomes `notify::selected` (:788 → :154)"},{name:`setting the index already held`,steps:[{op:`setOptions`,options:e},{op:`setSelectedIndex`,index:1},{op:`setSelectedIndex`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:`the setter returns before touching the selection when the position holds (:785-786) — no notify`},{name:`the chooser pick`,steps:[{op:`setOptions`,options:e},{op:`select`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!0}],rule:"the popup routes its position through the SAME setter (:209); only the `interactive` tag differs, and that tag is ours"},{name:`picking the option already selected`,steps:[{op:`setOptions`,options:e},{op:`select`,index:0}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`the same-position guard (:785-786) applies to the user path too — reopening and re-picking notifies nothing`},{name:`a dismissed chooser`,steps:[{op:`setOptions`,options:e},{op:`select`,index:-1}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`no C equivalent: a dismissed native sheet resolves to the cancel label, so the renderer looks up -1 — the guard is the substitution's`},{name:`select by value`,steps:[{op:`setOptions`,options:e},{op:`setSelectedValue`,value:`b`}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:`a value maps to the FIRST option carrying it; the port addition over the C, whose model is positional`},{name:`select by an unknown value`,steps:[{op:`setOptions`,options:e},{op:`setSelectedValue`,value:`zzz`}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`an unknown value is a no-op, never a reset to 0 — a mistyped binding must not silently move the selection`},{name:`the model is replaced at the same index`,steps:[{op:`setOptions`,options:[{label:`First`,value:`a`}]},{op:`setOptions`,options:[{label:`Renamed`,value:`a`}]}],selected:0,value:`a`,label:`Renamed`,emitted:[{selected:0,value:`a`,label:`First`,interactive:!1},{selected:0,value:`a`,label:`Renamed`,interactive:!1}],rule:"the index did not move but the ITEM did — `selection_item_changed` (:157-185) repaints off the item, not the position"},{name:`the model shrinks past the selection`,steps:[{op:`setOptions`,options:e},{op:`setSelectedIndex`,index:1},{op:`setOptions`,options:[{label:`Only`,value:`a`}]}],selected:0,value:`a`,label:`Only`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1},{selected:0,value:`a`,label:`Only`,interactive:!1}],rule:`a selection past the end of the new model falls back to 0 — GtkSingleSelection autoselects upstream, whose C is not vendored here, so this row is the ports' shared answer`},{name:`an index past the end`,steps:[{op:`setOptions`,options:[{label:`Only`,value:`a`}]},{op:`setSelectedIndex`,index:5}],selected:5,value:``,label:``,emitted:[{selected:0,value:`a`,label:`Only`,interactive:!1},{selected:5,value:``,label:``,interactive:!1}],rule:`the index is NOT clamped (the C takes any guint); the empty value/label is how "nothing to draw" is expressed here`},{name:`an empty model`,steps:[{op:`setOptions`,options:[]}],selected:-1,value:``,label:``,emitted:[{selected:-1,value:``,label:``,interactive:!1}],rule:`GTK_INVALID_LIST_POSITION (:593-596, :809-810) — an empty model has no index 0 to autoselect`},{name:`picking from an empty model`,steps:[{op:`setOptions`,options:[]},{op:`select`,index:0}],selected:-1,value:``,label:``,emitted:[{selected:-1,value:``,label:``,interactive:!1}],rule:`there is no option 0 to pick — and the renderers never open a chooser over an empty model either`},{name:`emptying a model that had a selection`,steps:[{op:`setOptions`,options:e},{op:`setSelectedIndex`,index:1},{op:`setOptions`,options:[]}],selected:-1,value:``,label:``,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1},{selected:-1,value:``,label:``,interactive:!1}],rule:`the selection does NOT survive as index 0 — there is nothing at 0 any more`},{name:`a model that is emptied and refilled`,steps:[{op:`setOptions`,options:e},{op:`setOptions`,options:[]},{op:`setOptions`,options:e}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:-1,value:``,label:``,interactive:!1},{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`autoselect runs again, so the sentinel recovers to 0 — it is BELOW the range, which a one-sided >= length check leaves in place`},{name:`a model with an empty first label is still a selection`,steps:[{op:`setOptions`,options:[{label:``,value:`blank`}]}],selected:0,value:`blank`,label:``,emitted:[{selected:0,value:`blank`,label:``,interactive:!1}],rule:`the case the sentinel exists to separate: an empty LABEL, not an empty model`}],n=[{count:0,presentsChooser:!1,rule:`an empty model is not a chooser`},{count:1,presentsChooser:!1,rule:`ONE option is not a choice — the arrow goes and the row goes inert`},{count:2,presentsChooser:!0,rule:`two is the smallest real choice — the predicate is > 1, not >= 1`},{count:5,presentsChooser:!0,rule:`and anything above it`}];export{n as COMBO_CHOOSER_VECTORS,t as COMBO_SELECTION_VECTORS};
1
+ const e=[{label:`One`,value:`a`},{label:`Two`,value:`b`}],t=[{name:`programmatic index set`,steps:[{op:`setModel`,model:e},{op:`setSelectedIndex`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:"a changed position reaches the selection, whose notify becomes `notify::selected` (:788 → :154)"},{name:`setting the index already held`,steps:[{op:`setModel`,model:e},{op:`setSelectedIndex`,index:1},{op:`setSelectedIndex`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:`the setter returns before touching the selection when the position holds (:785-786) — no notify`},{name:`the chooser pick`,steps:[{op:`setModel`,model:e},{op:`select`,index:1}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!0}],rule:"the popup routes its position through the SAME setter (:209); only the `interactive` tag differs, and that tag is ours"},{name:`picking the option already selected`,steps:[{op:`setModel`,model:e},{op:`select`,index:0}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`the same-position guard (:785-786) applies to the user path too — reopening and re-picking notifies nothing`},{name:`a dismissed chooser`,steps:[{op:`setModel`,model:e},{op:`select`,index:-1}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`no C equivalent: a dismissed native sheet resolves to the cancel label, so the renderer looks up -1 — the guard is the substitution's`},{name:`select by value`,steps:[{op:`setModel`,model:e},{op:`setSelectedValue`,value:`b`}],selected:1,value:`b`,label:`Two`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1}],rule:`a value maps to the FIRST option carrying it; the port addition over the C, whose model is positional`},{name:`select by an unknown value`,steps:[{op:`setModel`,model:e},{op:`setSelectedValue`,value:`zzz`}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`an unknown value is a no-op, never a reset to 0 — a mistyped binding must not silently move the selection`},{name:`the model is replaced at the same index`,steps:[{op:`setModel`,model:[{label:`First`,value:`a`}]},{op:`setModel`,model:[{label:`Renamed`,value:`a`}]}],selected:0,value:`a`,label:`Renamed`,emitted:[{selected:0,value:`a`,label:`First`,interactive:!1},{selected:0,value:`a`,label:`Renamed`,interactive:!1}],rule:"the index did not move but the ITEM did — `selection_item_changed` (:157-185) repaints off the item, not the position"},{name:`the model shrinks past the selection`,steps:[{op:`setModel`,model:e},{op:`setSelectedIndex`,index:1},{op:`setModel`,model:[{label:`Only`,value:`a`}]}],selected:0,value:`a`,label:`Only`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1},{selected:0,value:`a`,label:`Only`,interactive:!1}],rule:`a selection past the end of the new model falls back to 0 — GtkSingleSelection autoselects upstream, whose C is not vendored here, so this row is the ports' shared answer`},{name:`an index past the end`,steps:[{op:`setModel`,model:[{label:`Only`,value:`a`}]},{op:`setSelectedIndex`,index:5}],selected:5,value:``,label:``,emitted:[{selected:0,value:`a`,label:`Only`,interactive:!1},{selected:5,value:``,label:``,interactive:!1}],rule:`the index is NOT clamped (the C takes any guint); the empty value/label is how "nothing to draw" is expressed here`},{name:`an empty model`,steps:[{op:`setModel`,model:[]}],selected:-1,value:``,label:``,emitted:[{selected:-1,value:``,label:``,interactive:!1}],rule:`GTK_INVALID_LIST_POSITION (:593-596, :809-810) — an empty model has no index 0 to autoselect`},{name:`picking from an empty model`,steps:[{op:`setModel`,model:[]},{op:`select`,index:0}],selected:-1,value:``,label:``,emitted:[{selected:-1,value:``,label:``,interactive:!1}],rule:`there is no option 0 to pick — and the renderers never open a chooser over an empty model either`},{name:`emptying a model that had a selection`,steps:[{op:`setModel`,model:e},{op:`setSelectedIndex`,index:1},{op:`setModel`,model:[]}],selected:-1,value:``,label:``,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:1,value:`b`,label:`Two`,interactive:!1},{selected:-1,value:``,label:``,interactive:!1}],rule:`the selection does NOT survive as index 0 — there is nothing at 0 any more`},{name:`a model that is emptied and refilled`,steps:[{op:`setModel`,model:e},{op:`setModel`,model:[]},{op:`setModel`,model:e}],selected:0,value:`a`,label:`One`,emitted:[{selected:0,value:`a`,label:`One`,interactive:!1},{selected:-1,value:``,label:``,interactive:!1},{selected:0,value:`a`,label:`One`,interactive:!1}],rule:`autoselect runs again, so the sentinel recovers to 0 — it is BELOW the range, which a one-sided >= length check leaves in place`},{name:`a model with an empty first label is still a selection`,steps:[{op:`setModel`,model:[{label:``,value:`blank`}]}],selected:0,value:`blank`,label:``,emitted:[{selected:0,value:`blank`,label:``,interactive:!1}],rule:`the case the sentinel exists to separate: an empty LABEL, not an empty model`}],n=[{count:0,presentsChooser:!1,rule:`an empty model is not a chooser`},{count:1,presentsChooser:!1,rule:`ONE option is not a choice — the arrow goes and the row goes inert`},{count:2,presentsChooser:!0,rule:`two is the smallest real choice — the predicate is > 1, not >= 1`},{count:5,presentsChooser:!0,rule:`and anything above it`}];export{n as COMBO_CHOOSER_VECTORS,t as COMBO_SELECTION_VECTORS};
@@ -1 +1 @@
1
- const e=[{name:`icon-name (test_adw_split_button_icon_name, tests/test-split-button.c:17-55)`,steps:[{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`first icon on an empty button notifies icon-name only (:31-32)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!1,notified:[],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:"same icon again is a no-op — `if (!g_strcmp0 …) return` (:34-36 / c:756-757)"},{op:`icon-name`,value:`edit-find-symbolic`,changed:!0,notified:[`child`,`icon-name`],mode:`icon`,label:null,iconName:`edit-find-symbolic`,styleClasses:[`image-button`],rule:`icon→icon still notifies child: the internal GtkImage is non-NULL (:38-40 / c:762-763)`},{op:`label`,value:`Open`,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`setting the label CLEARS the icon — get_icon_name() is NULL after (:42-44)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`and back: setting the icon CLEARS the label (:46-48)`},{op:`child`,value:`child1`,changed:!0,notified:[`icon-name`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears both, and carries neither style class (:50-52)`}]},{name:`label (test_adw_split_button_label, tests/test-split-button.c:57-95)`,steps:[{op:`label`,value:`Open`,changed:!0,notified:[`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`first label on an empty button notifies label only (:71-72)`},{op:`label`,value:`Open`,changed:!1,notified:[],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`same label again is a no-op (:74-76 / c:668-669)`},{op:`label`,value:`Find`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Find`,iconName:null,styleClasses:[`text-button`],rule:`label→label notifies child: the internal GtkLabel is non-NULL (:78-80 / c:674-675)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`setting the icon CLEARS the label — get_label() is NULL after (:82-84)`},{op:`label`,value:`Open`,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`and back again (:86-88)`},{op:`child`,value:`child1`,changed:!0,notified:[`label`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears the label (:90-92)`}]},{name:`child (test_adw_split_button_child, tests/test-split-button.c:125-170)`,steps:[{op:`child`,value:null,changed:!1,notified:[],mode:`empty`,label:null,iconName:null,styleClasses:[],rule:`clearing an already-empty button is a no-op (:143-144 / c:806-807)`},{op:`child`,value:`child1`,changed:!0,notified:[`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`first child notifies child only (:146-148)`},{op:`child`,value:`child2`,changed:!0,notified:[`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`child→child notifies once; neither label nor icon was set (:150-152)`},{op:`label`,value:`Open`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`the label replaces the app child — get_child() is no longer it (:154-159)`},{op:`child`,value:`child3`,changed:!0,notified:[`label`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears the label back out (:161-163)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`the icon replaces the app child (:165-167)`}]},{name:`empty + whitespace labels (derived from adw-split-button.c:151-159, not asserted upstream)`,steps:[{op:`label`,value:``,changed:!0,notified:[`label`],mode:`label`,label:``,iconName:null,styleClasses:[],rule:"an empty label is SET (non-NULL) but `label[0]` is NUL — no text-button class (c:156)"},{op:`icon-name`,value:``,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:``,styleClasses:[],rule:`the empty label is still a non-NULL pointer, so it is notified as cleared (c:760-761)`},{op:`label`,value:` `,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:` `,iconName:null,styleClasses:[`text-button`],rule:"whitespace is a valid label: nothing trims, and `label[0]` is a space (c:156-159)"},{op:`label`,value:` `,changed:!1,notified:[],mode:`label`,label:` `,iconName:null,styleClasses:[`text-button`],rule:`g_strcmp0 is a byte compare — the same two spaces are the same label`},{op:`label`,value:`Änderungen speichern…`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Änderungen speichern…`,iconName:null,styleClasses:[`text-button`],rule:`non-ASCII is stored verbatim — no normalisation, no escaping (c:661-682)`}]}],t=[{label:`Open`,iconName:null,classes:[`text-button`],rule:`a label gives text-button (c:156-159)`},{label:null,iconName:`document-open-symbolic`,classes:[`image-button`],rule:`an icon gives image-button (c:151-154)`},{label:``,iconName:null,classes:[],rule:"`label[0]` is NUL — an empty label carries NO class"},{label:null,iconName:``,classes:[],rule:"`icon_name[0]` is NUL — an empty icon name carries NO class"},{label:` `,iconName:null,classes:[`text-button`],rule:`two spaces are a non-empty label — no trimming`},{label:` `,iconName:null,classes:[`text-button`],rule:`any non-NUL first byte counts, tab included`},{label:null,iconName:null,classes:[],rule:`a child (or nothing) carries neither class (c:145-165)`},{label:`Open`,iconName:`document-open-symbolic`,classes:[`image-button`,`text-button`],rule:`the two branches are independent and evaluated icon-first (c:151-159)`}],n=[{tooltip:``,text:`More Options`,markup:!1,rule:`unset/cleared restores the translated default as TEXT`},{tooltip:`Some tooltip`,text:`Some tooltip`,markup:!0,rule:`a set tooltip is markup (c:1046-1047)`},{tooltip:`Some <b>tooltip</b>`,text:`Some <b>tooltip</b>`,markup:!0,rule:`Pango markup passes through unescaped (c:428)`},{tooltip:` `,text:` `,markup:!0,rule:"`*tooltip` is a space — non-NUL, so it is a real tooltip"}],r=[{direction:`down`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"the default (c:420); glyph from `menubutton arrow.down`, not overridden (_buttons.scss:457-459)"},{direction:`up`,arrowIcon:`pan-up-symbolic`,popupDirection:`up`,rule:"`menubutton arrow.up`, not overridden (_buttons.scss:460-462)"},{direction:`left`,arrowIcon:`pan-start-symbolic`,popupDirection:`left`,rule:`left uses pan-START, not pan-left (_buttons.scss:463-465)`},{direction:`right`,arrowIcon:`pan-end-symbolic`,popupDirection:`right`,rule:`right uses pan-END (_buttons.scss:466-468)`},{direction:`none`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"WINNING selector `splitbutton > menubutton > button > arrow.none` (_buttons.scss:621-623) OVERRIDES `menubutton arrow.none` (:454-456): inside a split button `none` draws pan-down, NOT open-menu — and pops down (c:415), so it is indistinguishable from `down`"}],i=[{direction:`none`,arrowIcon:`open-menu-symbolic`,popupDirection:`down`,rule:"`menubutton arrow.none` (_buttons.scss:454-456) — the hamburger, unopposed here; placement still down (c:415 via the shared GtkMenuButton, c:971/:997)"},{direction:`down`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"`menubutton arrow.down` (_buttons.scss:457-459) — identical to the split button row"},{direction:`up`,arrowIcon:`pan-up-symbolic`,popupDirection:`up`,rule:"`menubutton arrow.up` (_buttons.scss:460-462)"},{direction:`left`,arrowIcon:`pan-start-symbolic`,popupDirection:`left`,rule:"`menubutton arrow.left` (_buttons.scss:463-465)"},{direction:`right`,arrowIcon:`pan-end-symbolic`,popupDirection:`right`,rule:"`menubutton arrow.right` (_buttons.scss:466-468)"}],a={active:!1,checked:!1,keyboardActivating:!1},o=[{action:a,dropdown:a,active:!1,checked:!1,rule:`idle folds to idle`},{action:{...a,active:!0},dropdown:a,active:!0,checked:!1,rule:`a pressed action half makes the WHOLE control active (c:134-137)`},{action:a,dropdown:{...a,active:!0},active:!0,checked:!1,rule:`so does a pressed dropdown half — the flags are OR-ed (c:127-128)`},{action:a,dropdown:{...a,checked:!0},active:!1,checked:!0,rule:`an open menu checks the arrow half, and the root with it (c:139-142)`},{action:{...a,keyboardActivating:!0},dropdown:a,active:!0,checked:!1,rule:`the keyboard-activating CSS class counts as ACTIVE (c:130-135)`},{action:{...a,active:!0},dropdown:{...a,checked:!0},active:!0,checked:!0,rule:`active and checked are independent folds`}],s=[{json:`[{"label":"Save as…","action":"app.save-as"}]`,entries:[{label:`Save as…`,action:`app.save-as`}],rule:`the GTK shape: (label, detailed action) pairs (c:385-388)`},{json:`[{"label":"Copy","action":"app.copy"},{"label":"Copy","action":"app.copy-special"}]`,entries:[{label:`Copy`,action:`app.copy`},{label:`Copy`,action:`app.copy-special`}],rule:`duplicate labels are legal and must NOT collapse`},{json:`[{"label":"About","id":"about","icon":"help-about-symbolic"}]`,entries:[{label:`About`,id:`about`,icon:`help-about-symbolic`}],rule:`the menu-button extras (id/icon) share the same entry type`},{json:null,entries:[],rule:`no attribute → no menu`},{json:``,entries:[],rule:`an empty attribute → no menu`},{json:`not json at all`,entries:[],rule:`malformed JSON degrades to no menu, it does not throw`},{json:`{"label":"Save"}`,entries:[],rule:`a non-array root is rejected wholesale`},{json:`[]`,entries:[],rule:`an empty array is an empty menu`},{json:`[{"action":"app.x"},null,42,["label"]]`,entries:[],rule:"entries without a `label` key are dropped"},{json:`[{"label":42,"action":7}]`,entries:[{label:`42`}],rule:`the label is String()-coerced; a non-string action is dropped rather than leaked`}],c=[{label:`Copy`,action:`app.copy`},{label:`Copy`,action:`app.copy-special`}],l=[{entries:c,index:1,activated:{label:`Copy`,action:`app.copy-special`},rule:`the SECOND of two identically labelled entries — the indexOf bug`},{entries:c,index:0,activated:{label:`Copy`,action:`app.copy`},rule:`position 0`},{entries:c,index:2,activated:null,rule:`a position past n_items has no item`},{entries:c,index:-1,activated:null,rule:`a negative position has no item`},{entries:c,index:.5,activated:null,rule:`a fractional position is not a position`},{entries:[],index:0,activated:null,rule:`no menu model → nothing to activate`}],u=[{entries:[],popover:!1,enabled:!1,canOpen:!1,rule:`neither → insensitive dropdown; an empty entry list is the renderers’ spelling of "no menu", so a menu-less button must not open an empty popover`},{entries:[{label:`Save as…`,action:`app.save-as`}],popover:!1,enabled:!0,canOpen:!0,rule:`a menu model makes the dropdown live`},{entries:[],popover:!0,enabled:!0,canOpen:!0,rule:`so does a popover on its own`},{entries:[{label:`Save as…`}],popover:!0,enabled:!0,canOpen:!0,rule:`setting one dissociates the other, but the dropdown stays live (c:390-403)`}];export{i as MENU_BUTTON_DIRECTION_VECTORS,e as SPLIT_BUTTON_CONTENT_VECTORS,r as SPLIT_BUTTON_DIRECTION_VECTORS,u as SPLIT_BUTTON_DROPDOWN_VECTORS,l as SPLIT_BUTTON_MENU_ACTIVATION_VECTORS,s as SPLIT_BUTTON_MENU_PARSE_VECTORS,o as SPLIT_BUTTON_ROOT_STATE_VECTORS,t as SPLIT_BUTTON_STYLE_CLASS_VECTORS,n as SPLIT_BUTTON_TOOLTIP_VECTORS};
1
+ const e=[{name:`icon-name (test_adw_split_button_icon_name, tests/test-split-button.c:17-55)`,steps:[{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`first icon on an empty button notifies icon-name only (:31-32)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!1,notified:[],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:"same icon again is a no-op — `if (!g_strcmp0 …) return` (:34-36 / c:756-757)"},{op:`icon-name`,value:`edit-find-symbolic`,changed:!0,notified:[`child`,`icon-name`],mode:`icon`,label:null,iconName:`edit-find-symbolic`,styleClasses:[`image-button`],rule:`icon→icon still notifies child: the internal GtkImage is non-NULL (:38-40 / c:762-763)`},{op:`label`,value:`Open`,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`setting the label CLEARS the icon — get_icon_name() is NULL after (:42-44)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`and back: setting the icon CLEARS the label (:46-48)`},{op:`child`,value:`child1`,changed:!0,notified:[`icon-name`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears both, and carries neither style class (:50-52)`}]},{name:`label (test_adw_split_button_label, tests/test-split-button.c:57-95)`,steps:[{op:`label`,value:`Open`,changed:!0,notified:[`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`first label on an empty button notifies label only (:71-72)`},{op:`label`,value:`Open`,changed:!1,notified:[],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`same label again is a no-op (:74-76 / c:668-669)`},{op:`label`,value:`Find`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Find`,iconName:null,styleClasses:[`text-button`],rule:`label→label notifies child: the internal GtkLabel is non-NULL (:78-80 / c:674-675)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`setting the icon CLEARS the label — get_label() is NULL after (:82-84)`},{op:`label`,value:`Open`,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`and back again (:86-88)`},{op:`child`,value:`child1`,changed:!0,notified:[`label`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears the label (:90-92)`}]},{name:`child (test_adw_split_button_child, tests/test-split-button.c:125-170)`,steps:[{op:`child`,value:null,changed:!1,notified:[],mode:`empty`,label:null,iconName:null,styleClasses:[],rule:`clearing an already-empty button is a no-op (:143-144 / c:806-807)`},{op:`child`,value:`child1`,changed:!0,notified:[`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`first child notifies child only (:146-148)`},{op:`child`,value:`child2`,changed:!0,notified:[`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`child→child notifies once; neither label nor icon was set (:150-152)`},{op:`label`,value:`Open`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Open`,iconName:null,styleClasses:[`text-button`],rule:`the label replaces the app child — get_child() is no longer it (:154-159)`},{op:`child`,value:`child3`,changed:!0,notified:[`label`,`child`],mode:`child`,label:null,iconName:null,styleClasses:[],rule:`a child clears the label back out (:161-163)`},{op:`icon-name`,value:`document-open-symbolic`,changed:!0,notified:[`child`,`icon-name`],mode:`icon`,label:null,iconName:`document-open-symbolic`,styleClasses:[`image-button`],rule:`the icon replaces the app child (:165-167)`}]},{name:`empty + whitespace labels (derived from adw-split-button.c:151-159, not asserted upstream)`,steps:[{op:`label`,value:``,changed:!0,notified:[`label`],mode:`label`,label:``,iconName:null,styleClasses:[],rule:"an empty label is SET (non-NULL) but `label[0]` is NUL — no text-button class (c:156)"},{op:`icon-name`,value:``,changed:!0,notified:[`label`,`child`,`icon-name`],mode:`icon`,label:null,iconName:``,styleClasses:[],rule:`the empty label is still a non-NULL pointer, so it is notified as cleared (c:760-761)`},{op:`label`,value:` `,changed:!0,notified:[`icon-name`,`child`,`label`],mode:`label`,label:` `,iconName:null,styleClasses:[`text-button`],rule:"whitespace is a valid label: nothing trims, and `label[0]` is a space (c:156-159)"},{op:`label`,value:` `,changed:!1,notified:[],mode:`label`,label:` `,iconName:null,styleClasses:[`text-button`],rule:`g_strcmp0 is a byte compare — the same two spaces are the same label`},{op:`label`,value:`Änderungen speichern…`,changed:!0,notified:[`child`,`label`],mode:`label`,label:`Änderungen speichern…`,iconName:null,styleClasses:[`text-button`],rule:`non-ASCII is stored verbatim — no normalisation, no escaping (c:661-682)`}]}],t=[{label:`Open`,iconName:null,classes:[`text-button`],rule:`a label gives text-button (c:156-159)`},{label:null,iconName:`document-open-symbolic`,classes:[`image-button`],rule:`an icon gives image-button (c:151-154)`},{label:``,iconName:null,classes:[],rule:"`label[0]` is NUL — an empty label carries NO class"},{label:null,iconName:``,classes:[],rule:"`icon_name[0]` is NUL — an empty icon name carries NO class"},{label:` `,iconName:null,classes:[`text-button`],rule:`two spaces are a non-empty label — no trimming`},{label:` `,iconName:null,classes:[`text-button`],rule:`any non-NUL first byte counts, tab included`},{label:null,iconName:null,classes:[],rule:`a child (or nothing) carries neither class (c:145-165)`},{label:`Open`,iconName:`document-open-symbolic`,classes:[`image-button`,`text-button`],rule:`the two branches are independent and evaluated icon-first (c:151-159)`}],n=[{tooltip:``,text:`More Options`,markup:!1,rule:`unset/cleared restores the translated default as TEXT`},{tooltip:`Some tooltip`,text:`Some tooltip`,markup:!0,rule:`a set tooltip is markup (c:1046-1047)`},{tooltip:`Some <b>tooltip</b>`,text:`Some <b>tooltip</b>`,markup:!0,rule:`Pango markup passes through unescaped (c:428)`},{tooltip:` `,text:` `,markup:!0,rule:"`*tooltip` is a space — non-NUL, so it is a real tooltip"}],r=[{direction:`down`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"the default (c:420); glyph from `menubutton arrow.down`, not overridden (_buttons.scss:457-459)"},{direction:`up`,arrowIcon:`pan-up-symbolic`,popupDirection:`up`,rule:"`menubutton arrow.up`, not overridden (_buttons.scss:460-462)"},{direction:`left`,arrowIcon:`pan-start-symbolic`,popupDirection:`left`,rule:`left uses pan-START, not pan-left (_buttons.scss:463-465)`},{direction:`right`,arrowIcon:`pan-end-symbolic`,popupDirection:`right`,rule:`right uses pan-END (_buttons.scss:466-468)`},{direction:`none`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"WINNING selector `splitbutton > menubutton > button > arrow.none` (_buttons.scss:621-623) OVERRIDES `menubutton arrow.none` (:454-456): inside a split button `none` draws pan-down, NOT open-menu — and pops down (c:415), so it is indistinguishable from `down`"}],i=[{direction:`none`,arrowIcon:`open-menu-symbolic`,popupDirection:`down`,rule:"`menubutton arrow.none` (_buttons.scss:454-456) — the hamburger, unopposed here; placement still down (c:415 via the shared GtkMenuButton, c:971/:997)"},{direction:`down`,arrowIcon:`pan-down-symbolic`,popupDirection:`down`,rule:"`menubutton arrow.down` (_buttons.scss:457-459) — identical to the split button row"},{direction:`up`,arrowIcon:`pan-up-symbolic`,popupDirection:`up`,rule:"`menubutton arrow.up` (_buttons.scss:460-462)"},{direction:`left`,arrowIcon:`pan-start-symbolic`,popupDirection:`left`,rule:"`menubutton arrow.left` (_buttons.scss:463-465)"},{direction:`right`,arrowIcon:`pan-end-symbolic`,popupDirection:`right`,rule:"`menubutton arrow.right` (_buttons.scss:466-468)"}],a={active:!1,checked:!1,keyboardActivating:!1},o=[{action:a,dropdown:a,active:!1,checked:!1,rule:`idle folds to idle`},{action:{...a,active:!0},dropdown:a,active:!0,checked:!1,rule:`a pressed action half makes the WHOLE control active (c:134-137)`},{action:a,dropdown:{...a,active:!0},active:!0,checked:!1,rule:`so does a pressed dropdown half — the flags are OR-ed (c:127-128)`},{action:a,dropdown:{...a,checked:!0},active:!1,checked:!0,rule:`an open menu checks the arrow half, and the root with it (c:139-142)`},{action:{...a,keyboardActivating:!0},dropdown:a,active:!0,checked:!1,rule:`the keyboard-activating CSS class counts as ACTIVE (c:130-135)`},{action:{...a,active:!0},dropdown:{...a,checked:!0},active:!0,checked:!0,rule:`active and checked are independent folds`}],s=[{kind:`item`,label:`Copy`,action:`app.copy`},{kind:`item`,label:`Copy`,action:`app.copy-special`},{kind:`submenu`,label:`More`,items:[{kind:`item`,label:`Copy`,action:`app.copy-as`}]}],c=[{model:s,path:[1],activated:{kind:`item`,label:`Copy`,action:`app.copy-special`},rule:`the SECOND of two identically labelled entries — the indexOf bug`},{model:s,path:[0],activated:{kind:`item`,label:`Copy`,action:`app.copy`},rule:`position 0`},{model:s,path:[2,0],activated:{kind:`item`,label:`Copy`,action:`app.copy-as`},rule:`a THIRD entry with the same label, inside a submenu: only a path tells it from the other two`},{model:s,path:[2],activated:null,rule:`a submenu is not an item — opening it activates nothing`},{model:s,path:[3],activated:null,rule:`a position past n_items has no item`},{model:s,path:[-1],activated:null,rule:`a negative position has no item`},{model:s,path:[.5],activated:null,rule:`a fractional position is not a position`},{model:s,path:[],activated:null,rule:`the empty path names the model, not an item`},{model:s,path:[0,0],activated:null,rule:`an item has no children to descend into`},{model:[],path:[0],activated:null,rule:`no menu model → nothing to activate`}],l=[{model:[],popover:!1,enabled:!1,canOpen:!1,rule:`neither → insensitive dropdown; an empty entry list is the renderers’ spelling of "no menu", so a menu-less button must not open an empty popover`},{model:[{kind:`item`,label:`Save as…`,action:`app.save-as`}],popover:!1,enabled:!0,canOpen:!0,rule:`a menu model makes the dropdown live`},{model:[],popover:!0,enabled:!0,canOpen:!0,rule:`so does a popover on its own`},{model:[{kind:`item`,label:`Save as…`}],popover:!0,enabled:!0,canOpen:!0,rule:`setting one dissociates the other, but the dropdown stays live (c:390-403)`},{model:[{kind:`section`,items:[]}],popover:!1,enabled:!0,canOpen:!0,rule:`a model with a node but nothing to DRAW is still a menu — the answer GTK gives for the same empty GMenu section`}];export{i as MENU_BUTTON_DIRECTION_VECTORS,e as SPLIT_BUTTON_CONTENT_VECTORS,r as SPLIT_BUTTON_DIRECTION_VECTORS,l as SPLIT_BUTTON_DROPDOWN_VECTORS,c as SPLIT_BUTTON_MENU_ACTIVATION_VECTORS,o as SPLIT_BUTTON_ROOT_STATE_VECTORS,t as SPLIT_BUTTON_STYLE_CLASS_VECTORS,n as SPLIT_BUTTON_TOOLTIP_VECTORS};
package/lib/esm/index.js CHANGED
@@ -1 +1 @@
1
- import{gStrStrip as e,glibClamp as t,stringIsNotEmpty as n,stripMnemonic as r}from"./glib.js";import{ADW_ABOUT_DIALOG_LABELS as i,ADW_CREDITS_SECTION_TITLES as a,ADW_LICENSES as o,ADW_LICENSE_ALIASES as s,ADW_LICENSE_DEFAULTS as c,ADW_LICENSE_WARRANTY_TEMPLATE as l,ADW_TRANSLATOR_CREDITS_SENTINELS as u,GTK_LICENSE as d,aboutDialogVisibility as f,creditsSections as p,isLicenseType as m,legalSectionVisible as h,licenseText as g,licenseTypeForSpdxId as _,parseCreditPerson as v,setLicense as y,setLicenseType as b,translatorCreditsPeople as x}from"./about-dialog.js";import{ADW_ACCENT_BG_COLORS as S,ADW_ACCENT_COLOR_NAMES as C,ADW_ACCENT_FG_COLOR as w,ADW_DEFAULT_ACCENT_COLOR as T,adwaitaAccent as E,adwaitaAccentBgColor as D,adwaitaAccentColor as O,adwaitaStandaloneColor as k,isAdwAccentColorName as A,onAdwaitaAccentChanged as j,setAdwaitaAccent as M}from"./accent.js";import{ActionRowState as N,BUTTON_ROW_ACTIVATABLE as P,ButtonRowState as F,SwitchRowState as I,WindowTitleState as L,deriveRowLabels as R}from"./action-row.js";import{AVATAR_COLORS as z,AVATAR_COLOR_COUNT as B,avatarColor as V,avatarColorClass as H,avatarFontSize as U,avatarInitials as W,avatarMaxFontSize as G,avatarMode as K,flattenAvatarGradient as q,gStrHash as J,randomAvatarColorClass as Y}from"./avatar.js";import{ADW_BANNER_BUTTON_STYLES as X,ADW_BANNER_BUTTON_STYLE_CLASSES as Z,ADW_BANNER_DEFAULTS as Q,bannerButtonStyleClasses as $,bannerButtonText as ee,bannerButtonVisible as te,bannerRenderState as ne,isBannerButtonStyle as re,parseBannerButtonStyle as ie}from"./banner.js";import{AdwBreakpoint as ae,evaluateBreakpointCondition as oe,parseBreakpointCondition as se}from"./breakpoint.js";import{BreakpointBinState as ce}from"./breakpoint-bin.js";import{ADW_BUTTON_CONTENT_DEFAULTS as le,BUTTON_CONTENT_BOX_SPACING as ue,BUTTON_CONTENT_FALLBACK_ICON as de,BUTTON_CONTENT_STYLE_CLASS as fe,buttonContentEllipsize as pe,buttonContentIconExpands as me,buttonContentIconIsEmpty as he,buttonContentIconName as ge,buttonContentLabelText as _e,buttonContentLabelVisible as ve,buttonContentRenderState as ye,buttonContentStyleTargetIndex as be}from"./button-content.js";import{ADW_BUTTON_STYLE_ALIASES as xe,ADW_BUTTON_STYLE_CLASSES as Se,buttonStyleClass as Ce,buttonStyleClasses as we}from"./button.js";import{ADW_SWIPE_DECELERATION_TOUCH as Te,ADW_SWIPE_DECELERATION_TOUCHPAD as Ee,ADW_SWIPE_DRAG_THRESHOLD as De,ADW_SWIPE_EPSILON as Oe,ADW_SWIPE_HISTORY_THRESHOLD_MS as ke,ADW_SWIPE_PARABOLA_MULTIPLIER as Ae,ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_H as je,ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_V as Me,ADW_SWIPE_VELOCITY_CURVE_THRESHOLD as Ne,ADW_SWIPE_VELOCITY_THRESHOLD_TOUCH as Pe,ADW_SWIPE_VELOCITY_THRESHOLD_TOUCHPAD as Fe,SwipeTracker as Ie,swipeBounds as Le,swipeClosestPointIndex as Re,swipeEndProgress as ze,swipeNextPointIndex as Be,swipePreviousPointIndex as Ve,swipeProjectedPointIndex as He,swipeSlope as Ue,swipeVelocityThreshold as We}from"./swipe.js";import{CAROUSEL_SCROLL_TIMEOUT_MS as Ge,CAROUSEL_SETTLE_EPSILON as Ke,CarouselState as qe,carouselClampPosition as Je,carouselClosestSnapPoint as Ye,carouselNavigateTarget as Xe,carouselPageAllocation as Ze,carouselPageAtPosition as Qe,carouselRange as $e,carouselReorderShift as et,carouselSizesFromSnapPoints as tt,carouselSnapPoints as nt,carouselWheelStep as rt}from"./carousel.js";import{RadioGroupState as it,resolveCheckState as at}from"./checks.js";import{adwLerp as ot,easeInOutSine as st,easeOutCubic as ct,inverseLerp as lt}from"./easing.js";import{ADW_CLAMP_DEFAULTS as ut,ADW_CLAMP_SIZE_CLASSES as dt,ADW_SPINNER_MAX_SIZE as ft,ADW_SPINNER_MIN_SIZE as pt,ADW_TOOLBAR_BAR_CLASSES as mt,ADW_TOOLBAR_VIEW_CLASSES as ht,ADW_TOOLBAR_VIEW_DEFAULTS as gt,clampAllocate as _t,clampChildSize as vt,clampSizeFromChild as yt,clampThresholds as bt,normalizeClampSize as xt,parseToolbarStyle as St,resolveSpinnerSize as Ct,spinnerGeometry as wt,toolbarBarStyleClasses as Tt,toolbarViewAllocate as Et,toolbarViewClasses as Dt,toolbarViewContentForSize as Ot,toolbarViewMeasure as kt}from"./chrome.js";import{DEFAULT_ICON_COLOR as At,DEFAULT_ICON_COLOR_DARK as jt,adwaitaColorScheme as Mt,isThemeIconColor as Nt,onAdwaitaColorSchemeChanged as Pt,setAdwaitaColorScheme as Ft,themeIconColor as It,toggleAdwaitaColorScheme as Lt}from"./color-scheme.js";import{ADW_DATA_GRID_ROW_VARIANTS as Rt,DATA_GRID_CELL_CLASS as zt,DATA_GRID_ROW_CLASS as Bt,dataGridCellText as Vt,dataGridColumnAlign as Ht,dataGridColumnClasses as Ut,dataGridRowInteractive as Wt,dataGridTrackTemplate as Gt,dataGridTracks as Kt,normalizeDataGridColumns as qt,normalizeDataGridVariant as Jt}from"./data-grid.js";import{AdwAlertResponses as Yt,BottomSheetPresentation as Xt,resolveBottomSheetClose as Zt}from"./dialog.js";import{CAPS_LOCK_ICON_NAME as Qt,CAPS_LOCK_TOOLTIP as $t,EMPTY_ANIMATION_DURATION_MS as en,ENTRY_ROW_APPLY_ICON_NAME as tn,ENTRY_ROW_APPLY_TOOLTIP as nn,ENTRY_ROW_EDIT_ICON_NAME as rn,ENTRY_ROW_MAX_LENGTH_LIMIT as an,ENTRY_ROW_TITLE_SPACING as on,EntryRowState as sn,PASSWORD_CONCEAL_ICON_NAME as cn,PASSWORD_CONCEAL_LABEL as ln,PASSWORD_REVEAL_ICON_NAME as un,PASSWORD_REVEAL_LABEL as dn,PasswordEntryRowState as fn,clampEntryText as pn,entryTextLength as mn}from"./entry-row.js";import{HeaderBarState as hn,resolveHeaderBarTitle as gn}from"./header-bar.js";import{AdwToast as _n,AdwToastQueue as vn,DEFAULT_TOAST_TIMEOUT as yn}from"./toast.js";import{ADW_COMBO_NO_SELECTION as bn,ComboState as xn,ExpanderState as Sn,SpinState as Cn,ToggleGroupState as wn,normalizeComboOptions as Tn}from"./rows.js";import{ViewStackState as En,normalizeIconName as Dn,resolvePageTitle as On}from"./view-stack.js";import{BACK_BUTTON_FALLBACK_TOOLTIP as kn,NavigationViewState as An,describeNavigationDiagnostic as jn}from"./navigation-view.js";import{ADW_SIDEBAR_NO_SELECTION as Mn,SidebarState as Nn,adjustSidebarSelection as Pn,clampSidebarSelection as Fn,flattenSidebarItems as In,sidebarHeaders as Ln}from"./sidebar.js";import{ADW_SPINNER_CONTRACT_DISTANCE as Rn,ADW_SPINNER_CYCLES_PER_LOOP as zn,ADW_SPINNER_CYCLE_LENGTH as Bn,ADW_SPINNER_EXTEND_DISTANCE as Vn,ADW_SPINNER_IDLE_DISTANCE as Hn,ADW_SPINNER_MAX_ARC_LENGTH as Un,ADW_SPINNER_MIN_ARC_LENGTH as Wn,ADW_SPINNER_N_CYCLES as Gn,ADW_SPINNER_OVERLAP_DISTANCE as Kn,ADW_SPINNER_SPIN_DURATION_MS as qn,ADW_SPINNER_START_ANGLE as Jn,ADW_SPINNER_STILL_PROGRESS as Yn,ADW_SPINNER_TRACK_OPACITY as Xn,normalizeSpinnerAngle as Zn,spinnerArc as Qn,spinnerArcEnd as $n,spinnerArcStart as er,spinnerProgressAt as tr}from"./spinner.js";import{parseAccelerator as nr,parseShortcutLabel as rr,shortcutKeycaps as ir}from"./shortcut-label.js";import{ADW_LENGTH_UNITS as ar,DEFAULT_DPI as or,adwLengthToPx as sr,normalizeLengthUnit as cr}from"./length-unit.js";import{ADW_SWIPE_BORDER as lr,DEFAULT_MAX_SIDEBAR_WIDTH as ur,DEFAULT_MIN_SIDEBAR_WIDTH as dr,DEFAULT_SIDEBAR_WIDTH_FRACTION as fr,DEFAULT_SIDEBAR_WIDTH_UNIT as pr,INSTANT_SPLIT_VIEW_ANIMATOR as mr,NAVIGATION_SPLIT_VIEW_CRITICALS as hr,NavigationSplitViewState as gr,OverlaySplitViewState as _r,isSidebarAtVisualStart as vr,layoutNavigationSplitView as yr,layoutOverlaySplitView as br,measureSplitViewHorizontal as xr,resolveNaturalSidebarWidth as Sr,resolveNavigationAction as Cr,resolveNavigationSidebarWidth as wr,resolveNavigationStack as Tr,resolveOverlaySidebarWidth as Er,resolveSidebarBounds as Dr,resolveSwipeArea as Or,resolveSwipeRelease as kr,resolveSwipeSnapPoints as Ar,resolveSwipeStart as jr,swipeCancelProgress as Mr,tagsConflict as Nr}from"./split-view.js";import{DEFAULT_DROPDOWN_TOOLTIP as Pr,SPLIT_BUTTON_DISABLED_OPACITY as Fr,SplitButtonState as Ir,isSplitButtonDirection as Lr,menuButtonArrowIcon as Rr,menuButtonPopupDirection as zr,parseMenuEntries as Br,resolveDropdownTooltip as Vr,splitButtonArrowIcon as Hr,splitButtonPopupDirection as Ur,splitButtonRootState as Wr,splitButtonStyleClasses as Gr}from"./split-button.js";import{DEFAULT_INDICATOR_DESCRIPTION_STRINGS as Kr,INLINE_VIEW_SWITCHER_DISPLAY_MODES as qr,VIEW_SWITCHER_BADGE_LIMIT as Jr,VIEW_SWITCHER_DRAG_SWITCH_DELAY as Yr,VIEW_SWITCHER_FALLBACK_ICON as Xr,VIEW_SWITCHER_NO_SELECTION as Zr,VIEW_SWITCHER_POLICIES as Qr,ViewSwitcherBarState as $r,ViewSwitcherDragSwitch as ei,ViewSwitcherState as ti,buildInlineToggles as ni,buildViewSwitcherButtons as ri,createViewSwitcherPage as ii,inlineToggleTooltip as ai,isInlineViewSwitcherDisplayMode as oi,isViewSwitcherButtonVisible as si,isViewSwitcherPolicy as ci,pageIndexForToggle as li,shouldRevealViewSwitcherBar as ui,toggleIndexForPage as di,viewSwitcherBadgeLabel as fi,viewSwitcherButtonOrientation as pi,viewSwitcherIconName as mi,viewSwitcherIndicatorDescription as hi,viewSwitcherLabel as gi,viewSwitcherPageFromStackPage as _i,viewSwitcherPagesFromStack as vi}from"./view-switcher.js";import{DEFAULT_TAB_AUTOHIDE as yi,TabViewState as bi,isDescendantOfPage as xi,successorAfterClose as Si,tabCloseVisible as Ci,tabIconState as wi,tabTooltip as Ti,tabTooltipIsMarkup as Ei,tabsRevealed as Di}from"./tab-view.js";import{UNTITLED_PAGE_LABEL as Oi,collectSearchRows as ki,countVisiblePages as Ai,createSearchRowSubtitle as ji,defaultCaseFolder as Mi,derivePreferencesGroupHeader as Ni,escapeMarkup as Pi,makeComparable as Fi,rowMatchesQuery as Ii,searchPreferences as Li,stripMarkup as Ri}from"./preferences.js";import{ADW_MAX_OVERSHOOT_DISTANCE as zi,ADW_OVERSHOOT_SETTLE_MS as Bi,ADW_UNDERSHOOT_CLASSES as Vi,ADW_UNDERSHOOT_SIZE as Hi,accumulateOvershoot as Ui,isScrolledFromEnd as Wi,isScrolledFromStart as Gi,overshootDistance as Ki,scrollMaxValue as qi,scrollUndershootClasses as Ji}from"./scrolling.js";import{POPOVER_ITEM_RADIUS as Yi,POPOVER_MENU_PADDING as Xi,POPOVER_PADDING as Zi,POPOVER_RADIUS as Qi,PopoverState as $i,resolvePopoverKey as ea}from"./popover.js";import{ADW_WRAP_BOX_DEFAULT_ALIGN as ta,ADW_WRAP_BOX_DEFAULT_JUSTIFY as na,ADW_WRAP_BOX_DEFAULT_JUSTIFY_LAST_LINE as ra,ADW_WRAP_BOX_DEFAULT_LENGTH_UNIT as ia,ADW_WRAP_BOX_DEFAULT_PACK_DIRECTION as aa,ADW_WRAP_BOX_DEFAULT_SPACING as oa,ADW_WRAP_BOX_DEFAULT_WRAP_POLICY as sa,ADW_WRAP_BOX_JUSTIFY_MODES as ca,ADW_WRAP_BOX_NATURAL_LINE_LENGTH_UNSET as la,ADW_WRAP_BOX_PACK_DIRECTIONS as ua,ADW_WRAP_POLICIES as da,normalizeNaturalLineLength as fa,normalizeWrapBoxAlign as pa,normalizeWrapBoxJustify as ma,normalizeWrapBoxLengthUnit as ha,normalizeWrapBoxPackDirection as ga,normalizeWrapBoxSpacing as _a,normalizeWrapPolicy as va,resolveWrapBoxChildOrder as ya,resolveWrapBoxLine as ba,wrapBoxChildFlex as xa,wrapBoxFlexStyle as Sa,wrapBoxLengthToPx as Ca,wrapPolicyFlexShrink as wa}from"./wrap-box.js";export{i as ADW_ABOUT_DIALOG_LABELS,S as ADW_ACCENT_BG_COLORS,C as ADW_ACCENT_COLOR_NAMES,w as ADW_ACCENT_FG_COLOR,X as ADW_BANNER_BUTTON_STYLES,Z as ADW_BANNER_BUTTON_STYLE_CLASSES,Q as ADW_BANNER_DEFAULTS,le as ADW_BUTTON_CONTENT_DEFAULTS,xe as ADW_BUTTON_STYLE_ALIASES,Se as ADW_BUTTON_STYLE_CLASSES,ut as ADW_CLAMP_DEFAULTS,dt as ADW_CLAMP_SIZE_CLASSES,bn as ADW_COMBO_NO_SELECTION,a as ADW_CREDITS_SECTION_TITLES,Rt as ADW_DATA_GRID_ROW_VARIANTS,T as ADW_DEFAULT_ACCENT_COLOR,ar as ADW_LENGTH_UNITS,o as ADW_LICENSES,s as ADW_LICENSE_ALIASES,c as ADW_LICENSE_DEFAULTS,l as ADW_LICENSE_WARRANTY_TEMPLATE,zi as ADW_MAX_OVERSHOOT_DISTANCE,Bi as ADW_OVERSHOOT_SETTLE_MS,Mn as ADW_SIDEBAR_NO_SELECTION,Rn as ADW_SPINNER_CONTRACT_DISTANCE,zn as ADW_SPINNER_CYCLES_PER_LOOP,Bn as ADW_SPINNER_CYCLE_LENGTH,Vn as ADW_SPINNER_EXTEND_DISTANCE,Hn as ADW_SPINNER_IDLE_DISTANCE,Un as ADW_SPINNER_MAX_ARC_LENGTH,ft as ADW_SPINNER_MAX_SIZE,Wn as ADW_SPINNER_MIN_ARC_LENGTH,pt as ADW_SPINNER_MIN_SIZE,Gn as ADW_SPINNER_N_CYCLES,Kn as ADW_SPINNER_OVERLAP_DISTANCE,qn as ADW_SPINNER_SPIN_DURATION_MS,Jn as ADW_SPINNER_START_ANGLE,Yn as ADW_SPINNER_STILL_PROGRESS,Xn as ADW_SPINNER_TRACK_OPACITY,lr as ADW_SWIPE_BORDER,Te as ADW_SWIPE_DECELERATION_TOUCH,Ee as ADW_SWIPE_DECELERATION_TOUCHPAD,De as ADW_SWIPE_DRAG_THRESHOLD,Oe as ADW_SWIPE_EPSILON,ke as ADW_SWIPE_HISTORY_THRESHOLD_MS,Ae as ADW_SWIPE_PARABOLA_MULTIPLIER,je as ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_H,Me as ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_V,Ne as ADW_SWIPE_VELOCITY_CURVE_THRESHOLD,Pe as ADW_SWIPE_VELOCITY_THRESHOLD_TOUCH,Fe as ADW_SWIPE_VELOCITY_THRESHOLD_TOUCHPAD,mt as ADW_TOOLBAR_BAR_CLASSES,ht as ADW_TOOLBAR_VIEW_CLASSES,gt as ADW_TOOLBAR_VIEW_DEFAULTS,u as ADW_TRANSLATOR_CREDITS_SENTINELS,Vi as ADW_UNDERSHOOT_CLASSES,Hi as ADW_UNDERSHOOT_SIZE,ta as ADW_WRAP_BOX_DEFAULT_ALIGN,na as ADW_WRAP_BOX_DEFAULT_JUSTIFY,ra as ADW_WRAP_BOX_DEFAULT_JUSTIFY_LAST_LINE,ia as ADW_WRAP_BOX_DEFAULT_LENGTH_UNIT,aa as ADW_WRAP_BOX_DEFAULT_PACK_DIRECTION,oa as ADW_WRAP_BOX_DEFAULT_SPACING,sa as ADW_WRAP_BOX_DEFAULT_WRAP_POLICY,ca as ADW_WRAP_BOX_JUSTIFY_MODES,la as ADW_WRAP_BOX_NATURAL_LINE_LENGTH_UNSET,ua as ADW_WRAP_BOX_PACK_DIRECTIONS,da as ADW_WRAP_POLICIES,z as AVATAR_COLORS,B as AVATAR_COLOR_COUNT,N as ActionRowState,Yt as AdwAlertResponses,ae as AdwBreakpoint,_n as AdwToast,vn as AdwToastQueue,kn as BACK_BUTTON_FALLBACK_TOOLTIP,ue as BUTTON_CONTENT_BOX_SPACING,de as BUTTON_CONTENT_FALLBACK_ICON,fe as BUTTON_CONTENT_STYLE_CLASS,P as BUTTON_ROW_ACTIVATABLE,Xt as BottomSheetPresentation,ce as BreakpointBinState,F as ButtonRowState,Qt as CAPS_LOCK_ICON_NAME,$t as CAPS_LOCK_TOOLTIP,Ge as CAROUSEL_SCROLL_TIMEOUT_MS,Ke as CAROUSEL_SETTLE_EPSILON,qe as CarouselState,xn as ComboState,zt as DATA_GRID_CELL_CLASS,Bt as DATA_GRID_ROW_CLASS,or as DEFAULT_DPI,Pr as DEFAULT_DROPDOWN_TOOLTIP,At as DEFAULT_ICON_COLOR,jt as DEFAULT_ICON_COLOR_DARK,Kr as DEFAULT_INDICATOR_DESCRIPTION_STRINGS,ur as DEFAULT_MAX_SIDEBAR_WIDTH,dr as DEFAULT_MIN_SIDEBAR_WIDTH,fr as DEFAULT_SIDEBAR_WIDTH_FRACTION,pr as DEFAULT_SIDEBAR_WIDTH_UNIT,yi as DEFAULT_TAB_AUTOHIDE,yn as DEFAULT_TOAST_TIMEOUT,en as EMPTY_ANIMATION_DURATION_MS,tn as ENTRY_ROW_APPLY_ICON_NAME,nn as ENTRY_ROW_APPLY_TOOLTIP,rn as ENTRY_ROW_EDIT_ICON_NAME,an as ENTRY_ROW_MAX_LENGTH_LIMIT,on as ENTRY_ROW_TITLE_SPACING,sn as EntryRowState,Sn as ExpanderState,d as GTK_LICENSE,hn as HeaderBarState,qr as INLINE_VIEW_SWITCHER_DISPLAY_MODES,mr as INSTANT_SPLIT_VIEW_ANIMATOR,hr as NAVIGATION_SPLIT_VIEW_CRITICALS,gr as NavigationSplitViewState,An as NavigationViewState,_r as OverlaySplitViewState,cn as PASSWORD_CONCEAL_ICON_NAME,ln as PASSWORD_CONCEAL_LABEL,un as PASSWORD_REVEAL_ICON_NAME,dn as PASSWORD_REVEAL_LABEL,Yi as POPOVER_ITEM_RADIUS,Xi as POPOVER_MENU_PADDING,Zi as POPOVER_PADDING,Qi as POPOVER_RADIUS,fn as PasswordEntryRowState,$i as PopoverState,it as RadioGroupState,Fr as SPLIT_BUTTON_DISABLED_OPACITY,Nn as SidebarState,Cn as SpinState,Ir as SplitButtonState,Ie as SwipeTracker,I as SwitchRowState,bi as TabViewState,wn as ToggleGroupState,Oi as UNTITLED_PAGE_LABEL,Jr as VIEW_SWITCHER_BADGE_LIMIT,Yr as VIEW_SWITCHER_DRAG_SWITCH_DELAY,Xr as VIEW_SWITCHER_FALLBACK_ICON,Zr as VIEW_SWITCHER_NO_SELECTION,Qr as VIEW_SWITCHER_POLICIES,En as ViewStackState,$r as ViewSwitcherBarState,ei as ViewSwitcherDragSwitch,ti as ViewSwitcherState,L as WindowTitleState,f as aboutDialogVisibility,Ui as accumulateOvershoot,Pn as adjustSidebarSelection,sr as adwLengthToPx,ot as adwLerp,E as adwaitaAccent,D as adwaitaAccentBgColor,O as adwaitaAccentColor,Mt as adwaitaColorScheme,k as adwaitaStandaloneColor,V as avatarColor,H as avatarColorClass,U as avatarFontSize,W as avatarInitials,G as avatarMaxFontSize,K as avatarMode,$ as bannerButtonStyleClasses,ee as bannerButtonText,te as bannerButtonVisible,ne as bannerRenderState,ni as buildInlineToggles,ri as buildViewSwitcherButtons,pe as buttonContentEllipsize,me as buttonContentIconExpands,he as buttonContentIconIsEmpty,ge as buttonContentIconName,_e as buttonContentLabelText,ve as buttonContentLabelVisible,ye as buttonContentRenderState,be as buttonContentStyleTargetIndex,Ce as buttonStyleClass,we as buttonStyleClasses,Je as carouselClampPosition,Ye as carouselClosestSnapPoint,Xe as carouselNavigateTarget,Ze as carouselPageAllocation,Qe as carouselPageAtPosition,$e as carouselRange,et as carouselReorderShift,tt as carouselSizesFromSnapPoints,nt as carouselSnapPoints,rt as carouselWheelStep,_t as clampAllocate,vt as clampChildSize,pn as clampEntryText,Fn as clampSidebarSelection,yt as clampSizeFromChild,bt as clampThresholds,ki as collectSearchRows,Ai as countVisiblePages,ji as createSearchRowSubtitle,ii as createViewSwitcherPage,p as creditsSections,Vt as dataGridCellText,Ht as dataGridColumnAlign,Ut as dataGridColumnClasses,Wt as dataGridRowInteractive,Gt as dataGridTrackTemplate,Kt as dataGridTracks,Mi as defaultCaseFolder,Ni as derivePreferencesGroupHeader,R as deriveRowLabels,jn as describeNavigationDiagnostic,st as easeInOutSine,ct as easeOutCubic,mn as entryTextLength,Pi as escapeMarkup,oe as evaluateBreakpointCondition,q as flattenAvatarGradient,In as flattenSidebarItems,J as gStrHash,e as gStrStrip,t as glibClamp,ai as inlineToggleTooltip,lt as inverseLerp,A as isAdwAccentColorName,re as isBannerButtonStyle,xi as isDescendantOfPage,oi as isInlineViewSwitcherDisplayMode,m as isLicenseType,Wi as isScrolledFromEnd,Gi as isScrolledFromStart,vr as isSidebarAtVisualStart,Lr as isSplitButtonDirection,Nt as isThemeIconColor,si as isViewSwitcherButtonVisible,ci as isViewSwitcherPolicy,yr as layoutNavigationSplitView,br as layoutOverlaySplitView,h as legalSectionVisible,g as licenseText,_ as licenseTypeForSpdxId,Fi as makeComparable,xr as measureSplitViewHorizontal,Rr as menuButtonArrowIcon,zr as menuButtonPopupDirection,xt as normalizeClampSize,Tn as normalizeComboOptions,qt as normalizeDataGridColumns,Jt as normalizeDataGridVariant,Dn as normalizeIconName,cr as normalizeLengthUnit,fa as normalizeNaturalLineLength,Zn as normalizeSpinnerAngle,pa as normalizeWrapBoxAlign,ma as normalizeWrapBoxJustify,ha as normalizeWrapBoxLengthUnit,ga as normalizeWrapBoxPackDirection,_a as normalizeWrapBoxSpacing,va as normalizeWrapPolicy,j as onAdwaitaAccentChanged,Pt as onAdwaitaColorSchemeChanged,Ki as overshootDistance,li as pageIndexForToggle,nr as parseAccelerator,ie as parseBannerButtonStyle,se as parseBreakpointCondition,v as parseCreditPerson,Br as parseMenuEntries,rr as parseShortcutLabel,St as parseToolbarStyle,Y as randomAvatarColorClass,Zt as resolveBottomSheetClose,at as resolveCheckState,Vr as resolveDropdownTooltip,gn as resolveHeaderBarTitle,Sr as resolveNaturalSidebarWidth,Cr as resolveNavigationAction,wr as resolveNavigationSidebarWidth,Tr as resolveNavigationStack,Er as resolveOverlaySidebarWidth,On as resolvePageTitle,ea as resolvePopoverKey,Dr as resolveSidebarBounds,Ct as resolveSpinnerSize,Or as resolveSwipeArea,kr as resolveSwipeRelease,Ar as resolveSwipeSnapPoints,jr as resolveSwipeStart,ya as resolveWrapBoxChildOrder,ba as resolveWrapBoxLine,Ii as rowMatchesQuery,qi as scrollMaxValue,Ji as scrollUndershootClasses,Li as searchPreferences,M as setAdwaitaAccent,Ft as setAdwaitaColorScheme,y as setLicense,b as setLicenseType,ir as shortcutKeycaps,ui as shouldRevealViewSwitcherBar,Ln as sidebarHeaders,Qn as spinnerArc,$n as spinnerArcEnd,er as spinnerArcStart,wt as spinnerGeometry,tr as spinnerProgressAt,Hr as splitButtonArrowIcon,Ur as splitButtonPopupDirection,Wr as splitButtonRootState,Gr as splitButtonStyleClasses,n as stringIsNotEmpty,Ri as stripMarkup,r as stripMnemonic,Si as successorAfterClose,Le as swipeBounds,Mr as swipeCancelProgress,Re as swipeClosestPointIndex,ze as swipeEndProgress,Be as swipeNextPointIndex,Ve as swipePreviousPointIndex,He as swipeProjectedPointIndex,Ue as swipeSlope,We as swipeVelocityThreshold,Ci as tabCloseVisible,wi as tabIconState,Ti as tabTooltip,Ei as tabTooltipIsMarkup,Di as tabsRevealed,Nr as tagsConflict,It as themeIconColor,Lt as toggleAdwaitaColorScheme,di as toggleIndexForPage,Tt as toolbarBarStyleClasses,Et as toolbarViewAllocate,Dt as toolbarViewClasses,Ot as toolbarViewContentForSize,kt as toolbarViewMeasure,x as translatorCreditsPeople,fi as viewSwitcherBadgeLabel,pi as viewSwitcherButtonOrientation,mi as viewSwitcherIconName,hi as viewSwitcherIndicatorDescription,gi as viewSwitcherLabel,_i as viewSwitcherPageFromStackPage,vi as viewSwitcherPagesFromStack,xa as wrapBoxChildFlex,Sa as wrapBoxFlexStyle,Ca as wrapBoxLengthToPx,wa as wrapPolicyFlexShrink};
1
+ import{gStrStrip as e,glibClamp as t,stringIsNotEmpty as n,stripMnemonic as r}from"./glib.js";import{ADW_ABOUT_DIALOG_LABELS as i,ADW_CREDITS_SECTION_TITLES as a,ADW_LICENSES as o,ADW_LICENSE_ALIASES as s,ADW_LICENSE_DEFAULTS as c,ADW_LICENSE_WARRANTY_TEMPLATE as l,ADW_TRANSLATOR_CREDITS_SENTINELS as u,GTK_LICENSE as d,aboutDialogVisibility as f,creditsSections as p,isLicenseType as m,legalSectionVisible as h,licenseText as g,licenseTypeForSpdxId as _,parseCreditPerson as v,setLicense as y,setLicenseType as b,translatorCreditsPeople as x}from"./about-dialog.js";import{ADW_ACCENT_BG_COLORS as S,ADW_ACCENT_COLOR_NAMES as C,ADW_ACCENT_FG_COLOR as w,ADW_DEFAULT_ACCENT_COLOR as T,adwaitaAccent as E,adwaitaAccentBgColor as D,adwaitaAccentColor as O,adwaitaStandaloneColor as k,isAdwAccentColorName as A,onAdwaitaAccentChanged as j,setAdwaitaAccent as M}from"./accent.js";import{ActionRowState as N,BUTTON_ROW_ACTIVATABLE as P,ButtonRowState as F,SwitchRowState as I,WindowTitleState as L,deriveRowLabels as R}from"./action-row.js";import{ADW_ADJUSTMENT_DEFAULTS as z,SpinState as B,adjustmentRange as V,clampAdjustmentValue as H,normalizeAdjustment as U,parseAdjustment as W,snapAdjustmentValue as G}from"./adjustment.js";import{AVATAR_COLORS as K,AVATAR_COLOR_COUNT as q,avatarColor as J,avatarColorClass as Y,avatarFontSize as X,avatarInitials as Z,avatarMaxFontSize as Q,avatarMode as $,flattenAvatarGradient as ee,gStrHash as te,randomAvatarColorClass as ne}from"./avatar.js";import{ADW_BANNER_BUTTON_STYLES as re,ADW_BANNER_BUTTON_STYLE_CLASSES as ie,ADW_BANNER_DEFAULTS as ae,bannerButtonStyleClasses as oe,bannerButtonText as se,bannerButtonVisible as ce,bannerRenderState as le,isBannerButtonStyle as ue,parseBannerButtonStyle as de}from"./banner.js";import{AdwBreakpoint as fe,evaluateBreakpointCondition as pe,parseBreakpointCondition as me}from"./breakpoint.js";import{BreakpointBinState as he}from"./breakpoint-bin.js";import{ADW_BUTTON_CONTENT_DEFAULTS as ge,BUTTON_CONTENT_BOX_SPACING as _e,BUTTON_CONTENT_FALLBACK_ICON as ve,BUTTON_CONTENT_STYLE_CLASS as ye,buttonContentEllipsize as be,buttonContentIconExpands as xe,buttonContentIconIsEmpty as Se,buttonContentIconName as Ce,buttonContentLabelText as we,buttonContentLabelVisible as Te,buttonContentRenderState as Ee,buttonContentStyleTargetIndex as De}from"./button-content.js";import{ADW_BUTTON_STYLE_ALIASES as Oe,ADW_BUTTON_STYLE_CLASSES as ke,buttonStyleClass as Ae,buttonStyleClasses as je}from"./button.js";import{ADW_SWIPE_DECELERATION_TOUCH as Me,ADW_SWIPE_DECELERATION_TOUCHPAD as Ne,ADW_SWIPE_DRAG_THRESHOLD as Pe,ADW_SWIPE_EPSILON as Fe,ADW_SWIPE_HISTORY_THRESHOLD_MS as Ie,ADW_SWIPE_PARABOLA_MULTIPLIER as Le,ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_H as Re,ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_V as ze,ADW_SWIPE_VELOCITY_CURVE_THRESHOLD as Be,ADW_SWIPE_VELOCITY_THRESHOLD_TOUCH as Ve,ADW_SWIPE_VELOCITY_THRESHOLD_TOUCHPAD as He,SwipeTracker as Ue,swipeBounds as We,swipeClosestPointIndex as Ge,swipeEndProgress as Ke,swipeNextPointIndex as qe,swipePreviousPointIndex as Je,swipeProjectedPointIndex as Ye,swipeSlope as Xe,swipeVelocityThreshold as Ze}from"./swipe.js";import{CAROUSEL_SCROLL_TIMEOUT_MS as Qe,CAROUSEL_SETTLE_EPSILON as $e,CarouselState as et,carouselClampPosition as tt,carouselClosestSnapPoint as nt,carouselNavigateTarget as rt,carouselPageAllocation as it,carouselPageAtPosition as at,carouselRange as ot,carouselReorderShift as st,carouselSizesFromSnapPoints as ct,carouselSnapPoints as lt,carouselWheelStep as ut}from"./carousel.js";import{RadioGroupState as dt,resolveCheckState as ft}from"./checks.js";import{adwLerp as pt,easeInOutSine as mt,easeOutCubic as ht,inverseLerp as gt}from"./easing.js";import{ADW_CLAMP_DEFAULTS as _t,ADW_CLAMP_SIZE_CLASSES as vt,ADW_SPINNER_MAX_SIZE as yt,ADW_SPINNER_MIN_SIZE as bt,ADW_TOOLBAR_BAR_CLASSES as xt,ADW_TOOLBAR_VIEW_CLASSES as St,ADW_TOOLBAR_VIEW_DEFAULTS as Ct,clampAllocate as wt,clampChildSize as Tt,clampSizeFromChild as Et,clampThresholds as Dt,normalizeClampSize as Ot,parseToolbarStyle as kt,resolveSpinnerSize as At,spinnerGeometry as jt,toolbarBarStyleClasses as Mt,toolbarViewAllocate as Nt,toolbarViewClasses as Pt,toolbarViewContentForSize as Ft,toolbarViewMeasure as It}from"./chrome.js";import{DEFAULT_ICON_COLOR as Lt,DEFAULT_ICON_COLOR_DARK as Rt,adwaitaColorScheme as zt,isThemeIconColor as Bt,onAdwaitaColorSchemeChanged as Vt,setAdwaitaColorScheme as Ht,themeIconColor as Ut,toggleAdwaitaColorScheme as Wt}from"./color-scheme.js";import{ViewStackState as Gt,normalizeIconName as Kt,resolvePageTitle as qt}from"./view-stack.js";import{DEFAULT_TAB_AUTOHIDE as Jt,TabViewState as Yt,isDescendantOfPage as Xt,successorAfterClose as Zt,tabCloseVisible as Qt,tabIconState as $t,tabTooltip as en,tabTooltipIsMarkup as tn,tabViewItemsChanged as nn,tabsRevealed as rn}from"./tab-view.js";import{ADW_DATA_GRID_ROW_VARIANTS as an,DATA_GRID_CELL_CLASS as on,DATA_GRID_ROW_CLASS as sn,dataGridCellText as cn,dataGridColumnAlign as ln,dataGridColumnClasses as un,dataGridRowInteractive as dn,dataGridTrackTemplate as fn,dataGridTracks as pn,normalizeDataGridColumns as mn,normalizeDataGridVariant as hn}from"./data-grid.js";import{AdwAlertResponses as gn,BottomSheetPresentation as _n,resolveBottomSheetClose as vn}from"./dialog.js";import{CAPS_LOCK_ICON_NAME as yn,CAPS_LOCK_TOOLTIP as bn,EMPTY_ANIMATION_DURATION_MS as xn,ENTRY_ROW_APPLY_ICON_NAME as Sn,ENTRY_ROW_APPLY_TOOLTIP as Cn,ENTRY_ROW_EDIT_ICON_NAME as wn,ENTRY_ROW_MAX_LENGTH_LIMIT as Tn,ENTRY_ROW_TITLE_SPACING as En,EntryRowState as Dn,PASSWORD_CONCEAL_ICON_NAME as On,PASSWORD_CONCEAL_LABEL as kn,PASSWORD_REVEAL_ICON_NAME as An,PASSWORD_REVEAL_LABEL as jn,PasswordEntryRowState as Mn,clampEntryText as Nn,entryTextLength as Pn}from"./entry-row.js";import{HeaderBarState as Fn,resolveHeaderBarTitle as In}from"./header-bar.js";import{AdwToast as Ln,AdwToastQueue as Rn,DEFAULT_TOAST_TIMEOUT as zn}from"./toast.js";import{ADW_COMBO_NO_SELECTION as Bn,clampListSelection as Vn,listItemsChanged as Hn,normalizeComboOptions as Un,parseListModel as Wn}from"./list.js";import{ComboState as Gn,ExpanderState as Kn,ToggleGroupState as qn}from"./rows.js";import{BACK_BUTTON_FALLBACK_TOOLTIP as Jn,NavigationViewState as Yn,describeNavigationDiagnostic as Xn}from"./navigation-view.js";import{ADW_SIDEBAR_NO_SELECTION as Zn,SidebarState as Qn,adjustSidebarSelection as $n,clampSidebarSelection as er,flattenSidebarItems as tr,sidebarHeaders as nr}from"./sidebar.js";import{ADW_SPINNER_CONTRACT_DISTANCE as rr,ADW_SPINNER_CYCLES_PER_LOOP as ir,ADW_SPINNER_CYCLE_LENGTH as ar,ADW_SPINNER_EXTEND_DISTANCE as or,ADW_SPINNER_IDLE_DISTANCE as sr,ADW_SPINNER_MAX_ARC_LENGTH as cr,ADW_SPINNER_MIN_ARC_LENGTH as lr,ADW_SPINNER_N_CYCLES as ur,ADW_SPINNER_OVERLAP_DISTANCE as dr,ADW_SPINNER_SPIN_DURATION_MS as fr,ADW_SPINNER_START_ANGLE as pr,ADW_SPINNER_STILL_PROGRESS as mr,ADW_SPINNER_TRACK_OPACITY as hr,normalizeSpinnerAngle as gr,spinnerArc as _r,spinnerArcEnd as vr,spinnerArcStart as yr,spinnerProgressAt as br}from"./spinner.js";import{parseAccelerator as xr,parseShortcutLabel as Sr,shortcutKeycaps as Cr}from"./shortcut-label.js";import{ADW_LENGTH_UNITS as wr,DEFAULT_DPI as Tr,adwLengthToPx as Er,normalizeLengthUnit as Dr}from"./length-unit.js";import{ADW_SWIPE_BORDER as Or,DEFAULT_MAX_SIDEBAR_WIDTH as kr,DEFAULT_MIN_SIDEBAR_WIDTH as Ar,DEFAULT_SIDEBAR_WIDTH_FRACTION as jr,DEFAULT_SIDEBAR_WIDTH_UNIT as Mr,INSTANT_SPLIT_VIEW_ANIMATOR as Nr,NAVIGATION_SPLIT_VIEW_CRITICALS as Pr,NavigationSplitViewState as Fr,OverlaySplitViewState as Ir,isSidebarAtVisualStart as Lr,layoutNavigationSplitView as Rr,layoutOverlaySplitView as zr,measureSplitViewHorizontal as Br,resolveNaturalSidebarWidth as Vr,resolveNavigationAction as Hr,resolveNavigationSidebarWidth as Ur,resolveNavigationStack as Wr,resolveOverlaySidebarWidth as Gr,resolveSidebarBounds as Kr,resolveSwipeArea as qr,resolveSwipeRelease as Jr,resolveSwipeSnapPoints as Yr,resolveSwipeStart as Xr,swipeCancelProgress as Zr,tagsConflict as Qr}from"./split-view.js";import{ADW_MENU_SURFACE_NATIVESCRIPT as $r,ADW_MENU_SURFACE_WEB as ei,assertMenuRenderable as ti,flattenMenu as ni,menuItemAt as ri,menuNodeAt as ii,menuRefusals as ai,normalizeMenuModel as oi,parseDetailedAction as si,parseMenuModel as ci,resolveMenuItemState as li}from"./menu.js";import{DEFAULT_DROPDOWN_TOOLTIP as ui,SPLIT_BUTTON_DISABLED_OPACITY as di,SplitButtonState as fi,isSplitButtonDirection as pi,menuButtonArrowIcon as mi,menuButtonPopupDirection as hi,resolveDropdownTooltip as gi,splitButtonArrowIcon as _i,splitButtonPopupDirection as vi,splitButtonRootState as yi,splitButtonStyleClasses as bi}from"./split-button.js";import{DEFAULT_INDICATOR_DESCRIPTION_STRINGS as xi,INLINE_VIEW_SWITCHER_DISPLAY_MODES as Si,VIEW_SWITCHER_BADGE_LIMIT as Ci,VIEW_SWITCHER_DRAG_SWITCH_DELAY as wi,VIEW_SWITCHER_FALLBACK_ICON as Ti,VIEW_SWITCHER_NO_SELECTION as Ei,VIEW_SWITCHER_POLICIES as Di,ViewSwitcherBarState as Oi,ViewSwitcherDragSwitch as ki,ViewSwitcherState as Ai,buildInlineToggles as ji,buildViewSwitcherButtons as Mi,createViewSwitcherPage as Ni,inlineToggleTooltip as Pi,isInlineViewSwitcherDisplayMode as Fi,isViewSwitcherButtonVisible as Ii,isViewSwitcherPolicy as Li,pageIndexForToggle as Ri,shouldRevealViewSwitcherBar as zi,toggleIndexForPage as Bi,viewSwitcherBadgeLabel as Vi,viewSwitcherButtonOrientation as Hi,viewSwitcherIconName as Ui,viewSwitcherIndicatorDescription as Wi,viewSwitcherLabel as Gi,viewSwitcherPageFromStackPage as Ki,viewSwitcherPagesFromStack as qi}from"./view-switcher.js";import{UNTITLED_PAGE_LABEL as Ji,collectSearchRows as Yi,countVisiblePages as Xi,createSearchRowSubtitle as Zi,defaultCaseFolder as Qi,derivePreferencesGroupHeader as $i,escapeMarkup as ea,makeComparable as ta,rowMatchesQuery as na,searchPreferences as ra,stripMarkup as ia}from"./preferences.js";import{ADW_MAX_OVERSHOOT_DISTANCE as aa,ADW_OVERSHOOT_SETTLE_MS as oa,ADW_UNDERSHOOT_CLASSES as sa,ADW_UNDERSHOOT_SIZE as ca,accumulateOvershoot as la,isScrolledFromEnd as ua,isScrolledFromStart as da,overshootDistance as fa,scrollMaxValue as pa,scrollUndershootClasses as ma}from"./scrolling.js";import{POPOVER_ITEM_RADIUS as ha,POPOVER_MENU_PADDING as ga,POPOVER_PADDING as _a,POPOVER_RADIUS as va,PopoverState as ya,resolvePopoverKey as ba}from"./popover.js";import{ADW_WRAP_BOX_DEFAULT_ALIGN as xa,ADW_WRAP_BOX_DEFAULT_JUSTIFY as Sa,ADW_WRAP_BOX_DEFAULT_JUSTIFY_LAST_LINE as Ca,ADW_WRAP_BOX_DEFAULT_LENGTH_UNIT as wa,ADW_WRAP_BOX_DEFAULT_PACK_DIRECTION as Ta,ADW_WRAP_BOX_DEFAULT_SPACING as Ea,ADW_WRAP_BOX_DEFAULT_WRAP_POLICY as Da,ADW_WRAP_BOX_JUSTIFY_MODES as Oa,ADW_WRAP_BOX_NATURAL_LINE_LENGTH_UNSET as ka,ADW_WRAP_BOX_PACK_DIRECTIONS as Aa,ADW_WRAP_POLICIES as ja,normalizeNaturalLineLength as Ma,normalizeWrapBoxAlign as Na,normalizeWrapBoxJustify as Pa,normalizeWrapBoxLengthUnit as Fa,normalizeWrapBoxPackDirection as Ia,normalizeWrapBoxSpacing as La,normalizeWrapPolicy as Ra,resolveWrapBoxChildOrder as za,resolveWrapBoxLine as Ba,wrapBoxChildFlex as Va,wrapBoxFlexStyle as Ha,wrapBoxLengthToPx as Ua,wrapPolicyFlexShrink as Wa}from"./wrap-box.js";export{i as ADW_ABOUT_DIALOG_LABELS,S as ADW_ACCENT_BG_COLORS,C as ADW_ACCENT_COLOR_NAMES,w as ADW_ACCENT_FG_COLOR,z as ADW_ADJUSTMENT_DEFAULTS,re as ADW_BANNER_BUTTON_STYLES,ie as ADW_BANNER_BUTTON_STYLE_CLASSES,ae as ADW_BANNER_DEFAULTS,ge as ADW_BUTTON_CONTENT_DEFAULTS,Oe as ADW_BUTTON_STYLE_ALIASES,ke as ADW_BUTTON_STYLE_CLASSES,_t as ADW_CLAMP_DEFAULTS,vt as ADW_CLAMP_SIZE_CLASSES,Bn as ADW_COMBO_NO_SELECTION,a as ADW_CREDITS_SECTION_TITLES,an as ADW_DATA_GRID_ROW_VARIANTS,T as ADW_DEFAULT_ACCENT_COLOR,wr as ADW_LENGTH_UNITS,o as ADW_LICENSES,s as ADW_LICENSE_ALIASES,c as ADW_LICENSE_DEFAULTS,l as ADW_LICENSE_WARRANTY_TEMPLATE,aa as ADW_MAX_OVERSHOOT_DISTANCE,$r as ADW_MENU_SURFACE_NATIVESCRIPT,ei as ADW_MENU_SURFACE_WEB,oa as ADW_OVERSHOOT_SETTLE_MS,Zn as ADW_SIDEBAR_NO_SELECTION,rr as ADW_SPINNER_CONTRACT_DISTANCE,ir as ADW_SPINNER_CYCLES_PER_LOOP,ar as ADW_SPINNER_CYCLE_LENGTH,or as ADW_SPINNER_EXTEND_DISTANCE,sr as ADW_SPINNER_IDLE_DISTANCE,cr as ADW_SPINNER_MAX_ARC_LENGTH,yt as ADW_SPINNER_MAX_SIZE,lr as ADW_SPINNER_MIN_ARC_LENGTH,bt as ADW_SPINNER_MIN_SIZE,ur as ADW_SPINNER_N_CYCLES,dr as ADW_SPINNER_OVERLAP_DISTANCE,fr as ADW_SPINNER_SPIN_DURATION_MS,pr as ADW_SPINNER_START_ANGLE,mr as ADW_SPINNER_STILL_PROGRESS,hr as ADW_SPINNER_TRACK_OPACITY,Or as ADW_SWIPE_BORDER,Me as ADW_SWIPE_DECELERATION_TOUCH,Ne as ADW_SWIPE_DECELERATION_TOUCHPAD,Pe as ADW_SWIPE_DRAG_THRESHOLD,Fe as ADW_SWIPE_EPSILON,Ie as ADW_SWIPE_HISTORY_THRESHOLD_MS,Le as ADW_SWIPE_PARABOLA_MULTIPLIER,Re as ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_H,ze as ADW_SWIPE_TOUCHPAD_BASE_DISTANCE_V,Be as ADW_SWIPE_VELOCITY_CURVE_THRESHOLD,Ve as ADW_SWIPE_VELOCITY_THRESHOLD_TOUCH,He as ADW_SWIPE_VELOCITY_THRESHOLD_TOUCHPAD,xt as ADW_TOOLBAR_BAR_CLASSES,St as ADW_TOOLBAR_VIEW_CLASSES,Ct as ADW_TOOLBAR_VIEW_DEFAULTS,u as ADW_TRANSLATOR_CREDITS_SENTINELS,sa as ADW_UNDERSHOOT_CLASSES,ca as ADW_UNDERSHOOT_SIZE,xa as ADW_WRAP_BOX_DEFAULT_ALIGN,Sa as ADW_WRAP_BOX_DEFAULT_JUSTIFY,Ca as ADW_WRAP_BOX_DEFAULT_JUSTIFY_LAST_LINE,wa as ADW_WRAP_BOX_DEFAULT_LENGTH_UNIT,Ta as ADW_WRAP_BOX_DEFAULT_PACK_DIRECTION,Ea as ADW_WRAP_BOX_DEFAULT_SPACING,Da as ADW_WRAP_BOX_DEFAULT_WRAP_POLICY,Oa as ADW_WRAP_BOX_JUSTIFY_MODES,ka as ADW_WRAP_BOX_NATURAL_LINE_LENGTH_UNSET,Aa as ADW_WRAP_BOX_PACK_DIRECTIONS,ja as ADW_WRAP_POLICIES,K as AVATAR_COLORS,q as AVATAR_COLOR_COUNT,N as ActionRowState,gn as AdwAlertResponses,fe as AdwBreakpoint,Ln as AdwToast,Rn as AdwToastQueue,Jn as BACK_BUTTON_FALLBACK_TOOLTIP,_e as BUTTON_CONTENT_BOX_SPACING,ve as BUTTON_CONTENT_FALLBACK_ICON,ye as BUTTON_CONTENT_STYLE_CLASS,P as BUTTON_ROW_ACTIVATABLE,_n as BottomSheetPresentation,he as BreakpointBinState,F as ButtonRowState,yn as CAPS_LOCK_ICON_NAME,bn as CAPS_LOCK_TOOLTIP,Qe as CAROUSEL_SCROLL_TIMEOUT_MS,$e as CAROUSEL_SETTLE_EPSILON,et as CarouselState,Gn as ComboState,on as DATA_GRID_CELL_CLASS,sn as DATA_GRID_ROW_CLASS,Tr as DEFAULT_DPI,ui as DEFAULT_DROPDOWN_TOOLTIP,Lt as DEFAULT_ICON_COLOR,Rt as DEFAULT_ICON_COLOR_DARK,xi as DEFAULT_INDICATOR_DESCRIPTION_STRINGS,kr as DEFAULT_MAX_SIDEBAR_WIDTH,Ar as DEFAULT_MIN_SIDEBAR_WIDTH,jr as DEFAULT_SIDEBAR_WIDTH_FRACTION,Mr as DEFAULT_SIDEBAR_WIDTH_UNIT,Jt as DEFAULT_TAB_AUTOHIDE,zn as DEFAULT_TOAST_TIMEOUT,xn as EMPTY_ANIMATION_DURATION_MS,Sn as ENTRY_ROW_APPLY_ICON_NAME,Cn as ENTRY_ROW_APPLY_TOOLTIP,wn as ENTRY_ROW_EDIT_ICON_NAME,Tn as ENTRY_ROW_MAX_LENGTH_LIMIT,En as ENTRY_ROW_TITLE_SPACING,Dn as EntryRowState,Kn as ExpanderState,d as GTK_LICENSE,Fn as HeaderBarState,Si as INLINE_VIEW_SWITCHER_DISPLAY_MODES,Nr as INSTANT_SPLIT_VIEW_ANIMATOR,Pr as NAVIGATION_SPLIT_VIEW_CRITICALS,Fr as NavigationSplitViewState,Yn as NavigationViewState,Ir as OverlaySplitViewState,On as PASSWORD_CONCEAL_ICON_NAME,kn as PASSWORD_CONCEAL_LABEL,An as PASSWORD_REVEAL_ICON_NAME,jn as PASSWORD_REVEAL_LABEL,ha as POPOVER_ITEM_RADIUS,ga as POPOVER_MENU_PADDING,_a as POPOVER_PADDING,va as POPOVER_RADIUS,Mn as PasswordEntryRowState,ya as PopoverState,dt as RadioGroupState,di as SPLIT_BUTTON_DISABLED_OPACITY,Qn as SidebarState,B as SpinState,fi as SplitButtonState,Ue as SwipeTracker,I as SwitchRowState,Yt as TabViewState,qn as ToggleGroupState,Ji as UNTITLED_PAGE_LABEL,Ci as VIEW_SWITCHER_BADGE_LIMIT,wi as VIEW_SWITCHER_DRAG_SWITCH_DELAY,Ti as VIEW_SWITCHER_FALLBACK_ICON,Ei as VIEW_SWITCHER_NO_SELECTION,Di as VIEW_SWITCHER_POLICIES,Gt as ViewStackState,Oi as ViewSwitcherBarState,ki as ViewSwitcherDragSwitch,Ai as ViewSwitcherState,L as WindowTitleState,f as aboutDialogVisibility,la as accumulateOvershoot,$n as adjustSidebarSelection,V as adjustmentRange,Er as adwLengthToPx,pt as adwLerp,E as adwaitaAccent,D as adwaitaAccentBgColor,O as adwaitaAccentColor,zt as adwaitaColorScheme,k as adwaitaStandaloneColor,ti as assertMenuRenderable,J as avatarColor,Y as avatarColorClass,X as avatarFontSize,Z as avatarInitials,Q as avatarMaxFontSize,$ as avatarMode,oe as bannerButtonStyleClasses,se as bannerButtonText,ce as bannerButtonVisible,le as bannerRenderState,ji as buildInlineToggles,Mi as buildViewSwitcherButtons,be as buttonContentEllipsize,xe as buttonContentIconExpands,Se as buttonContentIconIsEmpty,Ce as buttonContentIconName,we as buttonContentLabelText,Te as buttonContentLabelVisible,Ee as buttonContentRenderState,De as buttonContentStyleTargetIndex,Ae as buttonStyleClass,je as buttonStyleClasses,tt as carouselClampPosition,nt as carouselClosestSnapPoint,rt as carouselNavigateTarget,it as carouselPageAllocation,at as carouselPageAtPosition,ot as carouselRange,st as carouselReorderShift,ct as carouselSizesFromSnapPoints,lt as carouselSnapPoints,ut as carouselWheelStep,H as clampAdjustmentValue,wt as clampAllocate,Tt as clampChildSize,Nn as clampEntryText,Vn as clampListSelection,er as clampSidebarSelection,Et as clampSizeFromChild,Dt as clampThresholds,Yi as collectSearchRows,Xi as countVisiblePages,Zi as createSearchRowSubtitle,Ni as createViewSwitcherPage,p as creditsSections,cn as dataGridCellText,ln as dataGridColumnAlign,un as dataGridColumnClasses,dn as dataGridRowInteractive,fn as dataGridTrackTemplate,pn as dataGridTracks,Qi as defaultCaseFolder,$i as derivePreferencesGroupHeader,R as deriveRowLabels,Xn as describeNavigationDiagnostic,mt as easeInOutSine,ht as easeOutCubic,Pn as entryTextLength,ea as escapeMarkup,pe as evaluateBreakpointCondition,ee as flattenAvatarGradient,ni as flattenMenu,tr as flattenSidebarItems,te as gStrHash,e as gStrStrip,t as glibClamp,Pi as inlineToggleTooltip,gt as inverseLerp,A as isAdwAccentColorName,ue as isBannerButtonStyle,Xt as isDescendantOfPage,Fi as isInlineViewSwitcherDisplayMode,m as isLicenseType,ua as isScrolledFromEnd,da as isScrolledFromStart,Lr as isSidebarAtVisualStart,pi as isSplitButtonDirection,Bt as isThemeIconColor,Ii as isViewSwitcherButtonVisible,Li as isViewSwitcherPolicy,Rr as layoutNavigationSplitView,zr as layoutOverlaySplitView,h as legalSectionVisible,g as licenseText,_ as licenseTypeForSpdxId,Hn as listItemsChanged,ta as makeComparable,Br as measureSplitViewHorizontal,mi as menuButtonArrowIcon,hi as menuButtonPopupDirection,ri as menuItemAt,ii as menuNodeAt,ai as menuRefusals,U as normalizeAdjustment,Ot as normalizeClampSize,Un as normalizeComboOptions,mn as normalizeDataGridColumns,hn as normalizeDataGridVariant,Kt as normalizeIconName,Dr as normalizeLengthUnit,oi as normalizeMenuModel,Ma as normalizeNaturalLineLength,gr as normalizeSpinnerAngle,Na as normalizeWrapBoxAlign,Pa as normalizeWrapBoxJustify,Fa as normalizeWrapBoxLengthUnit,Ia as normalizeWrapBoxPackDirection,La as normalizeWrapBoxSpacing,Ra as normalizeWrapPolicy,j as onAdwaitaAccentChanged,Vt as onAdwaitaColorSchemeChanged,fa as overshootDistance,Ri as pageIndexForToggle,xr as parseAccelerator,W as parseAdjustment,de as parseBannerButtonStyle,me as parseBreakpointCondition,v as parseCreditPerson,si as parseDetailedAction,Wn as parseListModel,ci as parseMenuModel,Sr as parseShortcutLabel,kt as parseToolbarStyle,ne as randomAvatarColorClass,vn as resolveBottomSheetClose,ft as resolveCheckState,gi as resolveDropdownTooltip,In as resolveHeaderBarTitle,li as resolveMenuItemState,Vr as resolveNaturalSidebarWidth,Hr as resolveNavigationAction,Ur as resolveNavigationSidebarWidth,Wr as resolveNavigationStack,Gr as resolveOverlaySidebarWidth,qt as resolvePageTitle,ba as resolvePopoverKey,Kr as resolveSidebarBounds,At as resolveSpinnerSize,qr as resolveSwipeArea,Jr as resolveSwipeRelease,Yr as resolveSwipeSnapPoints,Xr as resolveSwipeStart,za as resolveWrapBoxChildOrder,Ba as resolveWrapBoxLine,na as rowMatchesQuery,pa as scrollMaxValue,ma as scrollUndershootClasses,ra as searchPreferences,M as setAdwaitaAccent,Ht as setAdwaitaColorScheme,y as setLicense,b as setLicenseType,Cr as shortcutKeycaps,zi as shouldRevealViewSwitcherBar,nr as sidebarHeaders,G as snapAdjustmentValue,_r as spinnerArc,vr as spinnerArcEnd,yr as spinnerArcStart,jt as spinnerGeometry,br as spinnerProgressAt,_i as splitButtonArrowIcon,vi as splitButtonPopupDirection,yi as splitButtonRootState,bi as splitButtonStyleClasses,n as stringIsNotEmpty,ia as stripMarkup,r as stripMnemonic,Zt as successorAfterClose,We as swipeBounds,Zr as swipeCancelProgress,Ge as swipeClosestPointIndex,Ke as swipeEndProgress,qe as swipeNextPointIndex,Je as swipePreviousPointIndex,Ye as swipeProjectedPointIndex,Xe as swipeSlope,Ze as swipeVelocityThreshold,Qt as tabCloseVisible,$t as tabIconState,en as tabTooltip,tn as tabTooltipIsMarkup,nn as tabViewItemsChanged,rn as tabsRevealed,Qr as tagsConflict,Ut as themeIconColor,Wt as toggleAdwaitaColorScheme,Bi as toggleIndexForPage,Mt as toolbarBarStyleClasses,Nt as toolbarViewAllocate,Pt as toolbarViewClasses,Ft as toolbarViewContentForSize,It as toolbarViewMeasure,x as translatorCreditsPeople,Vi as viewSwitcherBadgeLabel,Hi as viewSwitcherButtonOrientation,Ui as viewSwitcherIconName,Wi as viewSwitcherIndicatorDescription,Gi as viewSwitcherLabel,Ki as viewSwitcherPageFromStackPage,qi as viewSwitcherPagesFromStack,Va as wrapBoxChildFlex,Ha as wrapBoxFlexStyle,Ua as wrapBoxLengthToPx,Wa as wrapPolicyFlexShrink};
@@ -0,0 +1 @@
1
+ import"./_virtual/_rolldown/runtime.js";function normalizeComboOptions(e){return Array.isArray(e)?e.map(e=>{if(typeof e==`string`)return{value:e,label:e};let t=e?.value===void 0?String(e?.label??``):String(e.value);return{value:t,label:e?.label===void 0?t:String(e.label)}}):[]}function parseListModel(e){if(!e)return[];try{return normalizeComboOptions(JSON.parse(e))}catch{return[]}}const e=-1;function clampListSelection(e,t){return Number.isFinite(e)&&e>=0&&e<t?e:t===0?-1:0}function sameItem(e,t){return e!==void 0&&t!==void 0&&e.value===t.value&&e.label===t.label}function listItemsChanged(e,t){let n=e??[],r=t??[],i=Math.min(n.length,r.length),a=0;for(;a<i&&sameItem(n[a],r[a]);)a++;let o=0;for(;o<i-a&&sameItem(n[n.length-1-o],r[r.length-1-o]);)o++;let s=n.length-a-o,c=r.length-a-o;return s===0&&c===0?null:{position:a,removed:s,added:c}}export{e as ADW_COMBO_NO_SELECTION,clampListSelection,listItemsChanged,normalizeComboOptions,parseListModel};
@@ -0,0 +1,2 @@
1
+ import"./_virtual/_rolldown/runtime.js";const e=[`action-disabled`,`action-missing`,`macos-menubar`],t=[`horizontal-buttons`,`circular-buttons`,`inline-buttons`],n=[`ltr`,`rtl`,`none`],str=e=>typeof e==`string`?e:void 0;function oneOf(e,t){return typeof t==`string`&&e.includes(t)?t:void 0}function put(e,t,n){n!==void 0&&(e[t]=n)}function normalizeMenuModel(e){if(!Array.isArray(e))return[];let t=[];for(let n of e){let e=normalizeEntry(n);e!==null&&t.push(e)}return t}function normalizeEntry(r){if(typeof r==`string`)return{kind:`item`,label:r};if(typeof r!=`object`||!r)return null;let i=r;if(Array.isArray(i.items)&&(i.kind===`section`||i.kind===`submenu`)){let{items:e,kind:t,...n}=i;return normalizeEntry({...n,[t]:e})}if(Array.isArray(i.section)){let e={kind:`section`,items:normalizeMenuModel(i.section)},r=e;return put(r,`label`,str(i.label)),put(r,`displayHint`,oneOf(t,i.displayHint)),put(r,`textDirection`,oneOf(n,i.textDirection)),e}if(Array.isArray(i.submenu)){let e={kind:`submenu`,label:str(i.label)??``,items:normalizeMenuModel(i.submenu)},t=e;return put(t,`icon`,str(i.icon)),put(t,`submenuAction`,str(i.submenuAction)),put(t,`macosSpecial`,str(i.macosSpecial)),e}let a=str(i.label),o={kind:`item`,label:a??``},s=o;return put(s,`action`,str(i.action)||void 0),put(s,`icon`,str(i.icon)),put(s,`verbIcon`,str(i.verbIcon)),put(s,`accel`,str(i.accel)),put(s,`hiddenWhen`,oneOf(e,i.hiddenWhen)),put(s,`custom`,str(i.custom)),put(s,`id`,str(i.id)),i.useMarkup===!0&&(s.useMarkup=!0),a===void 0&&Object.keys(o).length===2?null:o}function parseMenuModel(e){if(!e)return[];let t;try{t=JSON.parse(e)}catch{return[]}return Array.isArray(t)?normalizeMenuModel(t):[]}function menuNodeAt(e,t){if(!Array.isArray(t)||t.length===0)return null;let n=e,r=null;for(let e of t){if(!Number.isInteger(e)||e<0||e>=n.length)return null;r=n[e],n=r.kind===`item`?[]:r.items}return r}function menuItemAt(e,t){let n=menuNodeAt(e,t);return n!==null&&n.kind===`item`?n:null}function flattenMenu(e,t=[]){let n=[],r=!1;return e.forEach((e,i)=>{let a=[...t,i];if(e.kind===`section`){let t=flattenMenu(e.items,a);if(t.length===0)return;n.push({...t[0],separated:n.length>0}),n.push(...t.slice(1)),r=!0;return}n.push({node:e,path:a,separated:r&&n.length>0}),r=!1}),n}function parseDetailedAction(e){if(typeof e!=`string`||e.length===0)return null;let t=e.indexOf(`::`);if(t>0)return{name:e.slice(0,t),target:e.slice(t+2)};let n=e.indexOf(`(`);return n>0&&e.endsWith(`)`)?{name:e.slice(0,n),target:unquote(e.slice(n+1,-1))}:{name:e}}function unquote(e){let t=e[0];if(!(e.length>=2&&(t===`'`||t===`"`)&&e[e.length-1]===t))return e;let n=e.slice(1,-1),r=``;for(let e=0;e<n.length;e+=1){let i=n[e],a=n[e+1];if(i===`\\`&&(a===t||a===`\\`)){r+=a,e+=1;continue}r+=i}return r}function resolveMenuItemState(e,t){let n=parseDetailedAction(e.action);if(t===void 0)return{sensitive:!0,toggled:!1,role:`normal`,visible:visibility(e,!0,!0)};if(n===null)return{sensitive:!0,toggled:!1,role:`normal`,visible:visibility(e,!1,!0)};let r=t?.[n.name];if(r===void 0)return{sensitive:!1,toggled:!1,role:`normal`,visible:visibility(e,!1,!1)};let i=r.enabled!==!1,a=`normal`,o=!1;return n.target!==void 0&&r.state!==void 0?(a=`radio`,o=r.state===n.target):(r.state===`true`||r.state===`false`)&&(a=`check`,o=r.state===`true`),{sensitive:i,toggled:o,role:a,visible:visibility(e,!0,i)}}function visibility(e,t,n){switch(e.hiddenWhen){case`action-missing`:return t;case`action-disabled`:return n;case`macos-menubar`:return!0;default:return!0}}const r={name:`adwaita-web`,custom:!1},i={name:`nativescript`,custom:!1};function menuRefusals(e,t,n=[]){let r=[];return e.forEach((e,i)=>{let a=[...n,i];if(e.kind===`item`){e.custom!==void 0&&!t.custom&&r.push({path:a,what:`custom`,message:`menu item custom="${e.custom}" names an application widget, which ${t.name} cannot host: it has no gtk_popover_menu_add_child. Give the item a label and an action, or keep this menu on GTK.`});return}r.push(...menuRefusals(e.items,t,a))}),r}function assertMenuRenderable(e,t){let n=menuRefusals(e,t);if(n.length===0)return;let r=n.map(e=>` [${e.path.join(`.`)}] ${e.message}`);throw Error(`${t.name} cannot render this menu:\n${r.join(`
2
+ `)}`)}export{i as ADW_MENU_SURFACE_NATIVESCRIPT,r as ADW_MENU_SURFACE_WEB,assertMenuRenderable,flattenMenu,menuItemAt,menuNodeAt,menuRefusals,normalizeMenuModel,parseDetailedAction,parseMenuModel,resolveMenuItemState};
package/lib/esm/rows.js CHANGED
@@ -1 +1 @@
1
- import"./_virtual/_rolldown/runtime.js";var ExpanderState=class{constructor(){this._expanded=!1,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(){for(let e of[...this._listeners])e(this._expanded)}get expanded(){return this._expanded}setExpanded(e){let t=!!e;return t===this._expanded?!1:(this._expanded=t,this._emit(),!0)}toggle(){return this.setExpanded(!this._expanded)}expand(){return this.setExpanded(!0)}collapse(){return this.setExpanded(!1)}};function normalizeComboOptions(e){return Array.isArray(e)?e.map(e=>{if(typeof e==`string`)return{value:e,label:e};let t=e?.value===void 0?String(e?.label??``):String(e.value);return{value:t,label:e?.label===void 0?t:String(e.label)}}):[]}const e=-1;var ComboState=class{constructor(){this._options=[],this._selected=0,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(e){let t={selected:this._selected,value:this.selectedValue,label:this.selectedLabel,interactive:e};for(let e of[...this._listeners])e(t)}_setIndex(e,t){return e===this._selected?!1:(this._selected=e,this._emit(t),!0)}get options(){return this._options}setOptions(e){this._options=Array.isArray(e)?e:[],this.hasIndex(this._selected)||(this._selected=this._options.length===0?-1:0),this._emit(!1)}get selectedIndex(){return this._selected}get presentsChooser(){return this._options.length>1}setSelectedIndex(e){return this._setIndex(Number.isFinite(e)?e:0,!1)}get selectedValue(){return this._options[this._selected]?.value??``}get selectedLabel(){return this._options[this._selected]?.label??``}setSelectedValue(e){let t=this._options.findIndex(t=>t.value===e);return t>=0?this.setSelectedIndex(t):!1}hasIndex(e){return Number.isFinite(e)&&e>=0&&e<this._options.length}select(e){return!this.hasIndex(e)||e===this._selected?!1:this._setIndex(e,!0)}get count(){return this._options.length}},SpinState=class{constructor(){this._value=0,this._min=0,this._max=100,this._step=1,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(e){let t={value:this._value,interactive:e};for(let e of[...this._listeners])e(t)}_clamp(e){return Math.min(this._max,Math.max(this._min,e))}_bump(e){let t=this._clamp(this._value+e);return t===this._value?!1:(this._value=t,this._emit(!0),!0)}_reclamp(){let e=this._clamp(this._value);return e===this._value?!1:(this._value=e,this._emit(!1),!0)}get value(){return this._value}get min(){return this._min}get max(){return this._max}get step(){return this._step}setValue(e){let t=this._clamp(Number.isFinite(e)?e:0);return t===this._value?!1:(this._value=t,this._emit(!1),!0)}setMin(e){return this._min=Number.isFinite(e)?e:0,this._reclamp()}setMax(e){return this._max=Number.isFinite(e)?e:0,this._reclamp()}setStep(e){this._step=Number.isFinite(e)&&e>0?e:1}increment(){return this._bump(this._step)}decrement(){return this._bump(-this._step)}},ToggleGroupState=class{constructor(){this._labels=[],this._selected=0,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(){let e={selected:this._selected,value:this.selectedValue};for(let t of[...this._listeners])t(e)}get labels(){return this._labels}setLabels(e){this._labels=Array.isArray(e)?e:[],this._selected>=this._labels.length&&(this._selected=0)}get selected(){return this._selected}setSelected(e){let t=Number.isFinite(e)?e:0;return t===this._selected||t<0||t>=this._labels.length?!1:(this._selected=t,this._emit(),!0)}get selectedValue(){return this._labels[this._selected]??``}get count(){return this._labels.length}};export{e as ADW_COMBO_NO_SELECTION,ComboState,ExpanderState,SpinState,ToggleGroupState,normalizeComboOptions};
1
+ import"./_virtual/_rolldown/runtime.js";import{SpinState as e}from"./adjustment.js";import{ADW_COMBO_NO_SELECTION as t,clampListSelection as n,listItemsChanged as r,normalizeComboOptions as i}from"./list.js";var ExpanderState=class{constructor(){this._expanded=!1,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(){for(let e of[...this._listeners])e(this._expanded)}get expanded(){return this._expanded}setExpanded(e){let t=!!e;return t===this._expanded?!1:(this._expanded=t,this._emit(),!0)}toggle(){return this.setExpanded(!this._expanded)}expand(){return this.setExpanded(!0)}collapse(){return this.setExpanded(!1)}},ComboState=class{constructor(){this._options=[],this._selected=0,this._listeners=new Set,this._itemListeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}subscribeItems(e){return this._itemListeners.add(e),()=>{this._itemListeners.delete(e)}}_emit(e){let t={selected:this._selected,value:this.selectedValue,label:this.selectedLabel,interactive:e};for(let e of[...this._listeners])e(t)}_setIndex(e,t){return e===this._selected?!1:(this._selected=e,this._emit(t),!0)}get model(){return this._options.map(e=>({value:e.value,label:e.label}))}setModel(e){let t=this._options,i=Array.isArray(e)?e:[],a=r(t,i);if(this._options=i.map(e=>({value:e.value,label:e.label})),this._selected=n(this._selected,i.length),a)for(let e of[...this._itemListeners])e(a);this._emit(!1)}get selectedIndex(){return this._selected}get presentsChooser(){return this._options.length>1}setSelectedIndex(e){return this._setIndex(Number.isFinite(e)?e:0,!1)}get selectedValue(){return this._options[this._selected]?.value??``}get selectedLabel(){return this._options[this._selected]?.label??``}setSelectedValue(e){let t=this._options.findIndex(t=>t.value===e);return t>=0?this.setSelectedIndex(t):!1}hasIndex(e){return Number.isFinite(e)&&e>=0&&e<this._options.length}select(e){return!this.hasIndex(e)||e===this._selected?!1:this._setIndex(e,!0)}get count(){return this._options.length}},ToggleGroupState=class{constructor(){this._labels=[],this._selected=0,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(){let e={selected:this._selected,value:this.selectedValue};for(let t of[...this._listeners])t(e)}get labels(){return this._labels}setLabels(e){this._labels=Array.isArray(e)?e:[],this._selected>=this._labels.length&&(this._selected=0)}get selected(){return this._selected}setSelected(e){let t=Number.isFinite(e)?e:0;return t===this._selected||t<0||t>=this._labels.length?!1:(this._selected=t,this._emit(),!0)}get selectedValue(){return this._labels[this._selected]??``}get count(){return this._labels.length}};export{t as ADW_COMBO_NO_SELECTION,ComboState,ExpanderState,e as SpinState,ToggleGroupState,i as normalizeComboOptions};
@@ -1 +1 @@
1
- import"./_virtual/_rolldown/runtime.js";const e=`More Options`,t=.5,n={none:`open-menu-symbolic`,down:`pan-down-symbolic`,up:`pan-up-symbolic`,left:`pan-start-symbolic`,right:`pan-end-symbolic`},r={...n,none:`pan-down-symbolic`},i=[`none`,`up`,`down`,`left`,`right`];function splitButtonStyleClasses(e,t){let n=[];return t!==null&&t.length>0&&n.push(`image-button`),e!==null&&e.length>0&&n.push(`text-button`),n}function resolveDropdownTooltip(t){return typeof t==`string`&&t.length>0?{text:t,markup:!0}:{text:e,markup:!1}}function menuButtonArrowIcon(e){return n[e]??n.down}function splitButtonArrowIcon(e){return r[e]??r.down}function splitButtonPopupDirection(e){return e===`none`||!i.includes(e)?`down`:e}const a=splitButtonPopupDirection;function isSplitButtonDirection(e){return typeof e==`string`&&i.includes(e)}function splitButtonRootState(e,t){return{active:e.active||t.active||e.keyboardActivating||t.keyboardActivating,checked:e.checked||t.checked}}function parseMenuEntries(e){if(!e)return[];let t;try{t=JSON.parse(e)}catch{return[]}if(!Array.isArray(t))return[];let n=[];for(let e of t){if(typeof e!=`object`||!e||!(`label`in e))continue;let t=e,r={label:String(t.label)};typeof t.action==`string`&&(r.action=t.action),typeof t.id==`string`&&(r.id=t.id),typeof t.icon==`string`&&(r.icon=t.icon),n.push(r)}return n}function internalContent(e){return Object.freeze({adwInternalContent:e})}function derivedPopover(){return Object.freeze({adwDerivedPopover:!0})}var SplitButtonState=class{constructor(){this._mode=`empty`,this._label=null,this._iconName=null,this._child=null,this._useUnderline=!1,this._menuModel=null,this._popover=null,this._direction=`down`,this._dropdownTooltip=``,this._open=!1,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(e,t){let n={mode:this._mode,label:this._label,iconName:this._iconName,child:this._child,styleClasses:this.styleClasses,dropdownEnabled:this.dropdownEnabled,open:this._open,notified:e,interactive:t};for(let e of[...this._listeners])e(n)}get mode(){return this._mode}get label(){return this._label}setLabel(e){if(typeof e!=`string`||e===this._label)return!1;let t=[];return this._iconName!==null&&t.push(`icon-name`),this._child!==null&&t.push(`child`),this._child=this._mode===`label`?this._child:internalContent(`label`),this._mode=`label`,this._label=e,this._iconName=null,t.push(`label`),this._emit(t,!1),!0}get iconName(){return this._iconName}setIconName(e){if(typeof e!=`string`||e===this._iconName)return!1;let t=[];return this._label!==null&&t.push(`label`),this._child!==null&&t.push(`child`),this._child=this._mode===`icon`?this._child:internalContent(`icon`),this._mode=`icon`,this._iconName=e,this._label=null,t.push(`icon-name`),this._emit(t,!1),!0}get child(){return this._child}setChild(e){let t=e??null;if(t===this._child)return!1;let n=[];return this._label!==null&&n.push(`label`),this._iconName!==null&&n.push(`icon-name`),this._mode=t===null?`empty`:`child`,this._child=t,this._label=null,this._iconName=null,n.push(`child`),this._emit(n,!1),!0}get styleClasses(){return splitButtonStyleClasses(this._label,this._iconName)}get useUnderline(){return this._useUnderline}setUseUnderline(e){let t=!!e;return t===this._useUnderline?!1:(this._useUnderline=t,this._emit([`use-underline`],!1),!0)}get menuModel(){return this._menuModel}setMenuModel(e){let t=e&&e.length>0?e:null;if(t===this._menuModel)return!1;let n=t===null?null:derivedPopover(),r=[];return n!==this._popover&&r.push(`popover`),r.push(`menu-model`),this._menuModel=t,this._popover=n,this.dropdownEnabled||(this._open=!1),this._emit(r,!1),!0}get popover(){return this._popover}setPopover(e){let t=e??null;if(t===this._popover)return!1;let n=[];return this._menuModel!==null&&n.push(`menu-model`),n.push(`popover`),this._menuModel=null,this._popover=t,this.dropdownEnabled||(this._open=!1),this._emit(n,!1),!0}get dropdownEnabled(){return this._menuModel!==null||this._popover!==null}get direction(){return this._direction}setDirection(e){return!isSplitButtonDirection(e)||e===this._direction?!1:(this._direction=e,this._emit([`direction`],!1),!0)}get arrowIcon(){return splitButtonArrowIcon(this._direction)}get dropdownTooltip(){return this._dropdownTooltip}setDropdownTooltip(e){return typeof e!=`string`||e===this._dropdownTooltip?!1:(this._dropdownTooltip=e,this._emit([`dropdown-tooltip`],!1),!0)}get open(){return this._open}_setOpen(e,t){return e&&!this.dropdownEnabled||e===this._open?!1:(this._open=e,this._emit([],t),!0)}openMenu(){return this._setOpen(!0,!1)}closeMenu(){return this._setOpen(!1,!1)}toggleMenu(){return this._setOpen(!this._open,!0)}activateMenuEntry(e){let t=this._menuModel;if(t===null||!Number.isInteger(e)||e<0||e>=t.length)return null;let n=t[e];return this._setOpen(!1,!0),n}};export{e as DEFAULT_DROPDOWN_TOOLTIP,t as SPLIT_BUTTON_DISABLED_OPACITY,SplitButtonState,isSplitButtonDirection,menuButtonArrowIcon,a as menuButtonPopupDirection,parseMenuEntries,resolveDropdownTooltip,splitButtonArrowIcon,splitButtonPopupDirection,splitButtonRootState,splitButtonStyleClasses};
1
+ import"./_virtual/_rolldown/runtime.js";import{menuItemAt as e,normalizeMenuModel as t}from"./menu.js";const n=`More Options`,r=.5,i={none:`open-menu-symbolic`,down:`pan-down-symbolic`,up:`pan-up-symbolic`,left:`pan-start-symbolic`,right:`pan-end-symbolic`},a={...i,none:`pan-down-symbolic`},o=[`none`,`up`,`down`,`left`,`right`];function splitButtonStyleClasses(e,t){let n=[];return t!==null&&t.length>0&&n.push(`image-button`),e!==null&&e.length>0&&n.push(`text-button`),n}function resolveDropdownTooltip(e){return typeof e==`string`&&e.length>0?{text:e,markup:!0}:{text:n,markup:!1}}function menuButtonArrowIcon(e){return i[e]??i.down}function splitButtonArrowIcon(e){return a[e]??a.down}function splitButtonPopupDirection(e){return e===`none`||!o.includes(e)?`down`:e}const s=splitButtonPopupDirection;function isSplitButtonDirection(e){return typeof e==`string`&&o.includes(e)}function splitButtonRootState(e,t){return{active:e.active||t.active||e.keyboardActivating||t.keyboardActivating,checked:e.checked||t.checked}}const menuKey=e=>e===null?``:JSON.stringify(e);function internalContent(e){return Object.freeze({adwInternalContent:e})}function derivedPopover(){return Object.freeze({adwDerivedPopover:!0})}var SplitButtonState=class{constructor(){this._mode=`empty`,this._label=null,this._iconName=null,this._child=null,this._useUnderline=!1,this._menuModel=null,this._popover=null,this._direction=`down`,this._dropdownTooltip=``,this._open=!1,this._listeners=new Set}subscribe(e){return this._listeners.add(e),()=>{this._listeners.delete(e)}}_emit(e,t){let n={mode:this._mode,label:this._label,iconName:this._iconName,child:this._child,styleClasses:this.styleClasses,dropdownEnabled:this.dropdownEnabled,open:this._open,notified:e,interactive:t};for(let e of[...this._listeners])e(n)}get mode(){return this._mode}get label(){return this._label}setLabel(e){if(typeof e!=`string`||e===this._label)return!1;let t=[];return this._iconName!==null&&t.push(`icon-name`),this._child!==null&&t.push(`child`),this._child=this._mode===`label`?this._child:internalContent(`label`),this._mode=`label`,this._label=e,this._iconName=null,t.push(`label`),this._emit(t,!1),!0}get iconName(){return this._iconName}setIconName(e){if(typeof e!=`string`||e===this._iconName)return!1;let t=[];return this._label!==null&&t.push(`label`),this._child!==null&&t.push(`child`),this._child=this._mode===`icon`?this._child:internalContent(`icon`),this._mode=`icon`,this._iconName=e,this._label=null,t.push(`icon-name`),this._emit(t,!1),!0}get child(){return this._child}setChild(e){let t=e??null;if(t===this._child)return!1;let n=[];return this._label!==null&&n.push(`label`),this._iconName!==null&&n.push(`icon-name`),this._mode=t===null?`empty`:`child`,this._child=t,this._label=null,this._iconName=null,n.push(`child`),this._emit(n,!1),!0}get styleClasses(){return splitButtonStyleClasses(this._label,this._iconName)}get useUnderline(){return this._useUnderline}setUseUnderline(e){let t=!!e;return t===this._useUnderline?!1:(this._useUnderline=t,this._emit([`use-underline`],!1),!0)}get menuModel(){return this._menuModel}setMenuModel(e){let n=t(e),r=n.length>0?n:null;if(menuKey(r)===menuKey(this._menuModel))return!1;let i=r===null?null:derivedPopover(),a=[];return i!==this._popover&&a.push(`popover`),a.push(`menu-model`),this._menuModel=r,this._popover=i,this.dropdownEnabled||(this._open=!1),this._emit(a,!1),!0}get popover(){return this._popover}setPopover(e){let t=e??null;if(t===this._popover)return!1;let n=[];return this._menuModel!==null&&n.push(`menu-model`),n.push(`popover`),this._menuModel=null,this._popover=t,this.dropdownEnabled||(this._open=!1),this._emit(n,!1),!0}get dropdownEnabled(){return this._menuModel!==null||this._popover!==null}get direction(){return this._direction}setDirection(e){return!isSplitButtonDirection(e)||e===this._direction?!1:(this._direction=e,this._emit([`direction`],!1),!0)}get arrowIcon(){return splitButtonArrowIcon(this._direction)}get dropdownTooltip(){return this._dropdownTooltip}setDropdownTooltip(e){return typeof e!=`string`||e===this._dropdownTooltip?!1:(this._dropdownTooltip=e,this._emit([`dropdown-tooltip`],!1),!0)}get open(){return this._open}_setOpen(e,t){return e&&!this.dropdownEnabled||e===this._open?!1:(this._open=e,this._emit([],t),!0)}openMenu(){return this._setOpen(!0,!1)}closeMenu(){return this._setOpen(!1,!1)}toggleMenu(){return this._setOpen(!this._open,!0)}activateMenuItem(t){if(this._menuModel===null)return null;let n=e(this._menuModel,t);return n===null?null:(this._setOpen(!1,!0),n)}};export{n as DEFAULT_DROPDOWN_TOOLTIP,r as SPLIT_BUTTON_DISABLED_OPACITY,SplitButtonState,isSplitButtonDirection,menuButtonArrowIcon,s as menuButtonPopupDirection,resolveDropdownTooltip,splitButtonArrowIcon,splitButtonPopupDirection,splitButtonRootState,splitButtonStyleClasses};
@@ -1 +1 @@
1
- import"./_virtual/_rolldown/runtime.js";import{ViewStackState as e}from"./view-stack.js";const t=!0;function tabsRevealed(e){return e.autohide?e.nPages>1||e.nPinnedPages>=1||e.isTransferringPage:!0}function tabCloseVisible(e){return e.pinned?!1:e.hovering&&e.fullyVisible||e.selected||e.dragging}function tabTooltip(e){return e.tooltip===``?e.title:e.tooltip}function tabTooltipIsMarkup(e){return e.tooltip!==``}function tabIconState(e,t){let n=e.indicatorIcon,r=e.icon;return!e.loading&&e.pinned&&r===null&&(r=t),{icon:r,spinner:e.loading,iconVisible:(r!==null||e.loading)&&(!e.pinned||n===null),indicatorVisible:n!==null}}function isDescendantOfPage(e,t,n){let r=t;for(;r!==null&&r!==n;)r=e.find(e=>e.id===r)?.parentId??null;return r===n}function successorAfterClose(e,t,n){if(t!==n)return n;let r=e.findIndex(e=>e.id===t);if(r<0)return n;let i=e[r].parentId;if(i!==null&&r>0){let t=e[r-1];if(isDescendantOfPage(e,t.id,i))return t.id;let n=e.find(e=>e.id===i);if(n&&t.pinned&&n.pinned)return n.id}return r<e.length-1?e[r+1].id:r>0?e[r-1].id:null}function assertionDiagnostic(e,t){return`${e}: assertion '${t}' failed`}var TabViewState=class{constructor(t={}){this._stack=new e,this._selectionListeners=new Set,this._pagesListeners=new Set,this._diagnostics=[],this._selectedId=null,this._deferSelection=!1,this._deferredSelection=null,this._pagesSource=null,this._pagesView=null,this._handlers=t,this._stack.subscribe(e=>{let t=this._selectedId,n=e.page?.content?.id??null;this._selectedId=n;let r={selectedId:n,selectedIndex:e.index,previousId:t,interactive:e.interactive};this._deferSelection?this._deferredSelection=r:this._emitSelection(r)})}subscribe(e){return this._selectionListeners.add(e),()=>{this._selectionListeners.delete(e)}}subscribePages(e){return this._pagesListeners.add(e),()=>{this._pagesListeners.delete(e)}}_emitSelection(e){for(let t of[...this._selectionListeners])t(e)}_emitPages(e){for(let t of[...this._pagesListeners])t(e)}_flushDeferredSelection(){let e=this._deferredSelection;e&&(this._deferredSelection=null,this._emitSelection(e))}get pages(){let e=this._stack.pages;return(this._pagesSource!==e||this._pagesView===null)&&(this._pagesSource=e,this._pagesView=Object.freeze(e.map(e=>e.content))),this._pagesView}get nPages(){return this._stack.count}get nPinnedPages(){let e=this.pages.findIndex(e=>!e.pinned);return e<0?this.pages.length:e}getNthPage(e){return!Number.isInteger(e)||e<0||e>=this.nPages?null:this.pages[e]}getPagePosition(e){return this._stack.indexOfName(e)}getPage(e){return this._recordOf(e)}isClosing(e){return this._recordOf(e)?.closing??!1}get diagnostics(){return this._diagnostics}get selectedId(){return this._stack.visiblePage?.content?.id??null}get selectedIndex(){return this._stack.visibleIndex}get selectedPage(){return this._stack.visiblePage?.content??null}setSelectedPage(e,t=!0){if(e===null)return this.nPages>0&&this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_selected_page`,`ADW_IS_TAB_PAGE (selected_page)`)),!1;let n=this.getPagePosition(e);return n<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_selected_page`,`page_belongs_to_this_view (self, selected_page)`)),!1):this._stack.setVisibleIndex(n,t)}selectNthPage(e){return this._stack.setVisibleIndex(e,!0)}selectPreviousPage(){let e=this.selectedIndex;return e<=0?!1:this._stack.setVisibleIndex(e-1,!0)}selectNextPage(){let e=this.selectedIndex;return e<0||e>=this.nPages-1?!1:this._stack.setVisibleIndex(e+1,!0)}selectFirstPage(){let e=this.selectedPage;if(!e)return!1;let t=e.pinned,n=this.getNthPage(t?0:this.nPinnedPages);return n===e&&!t&&(n=this.getNthPage(0)),!n||n===e?!1:this.setSelectedPage(n.id)}selectLastPage(){let e=this.selectedPage;if(!e)return!1;let t=e.pinned,n=this.getNthPage((t?this.nPinnedPages:this.nPages)-1);return n===e&&t&&(n=this.getNthPage(this.nPages-1)),!n||n===e?!1:this.setSelectedPage(n.id)}cycleNextPage(){return!this.selectedPage||this.nPages<=1?!1:this.selectNextPage()?!0:this._stack.setVisibleIndex(0,!0)}cyclePreviousPage(){return!this.selectedPage||this.nPages<=1?!1:this.selectPreviousPage()?!0:this._stack.setVisibleIndex(this.nPages-1,!0)}addPage(e,t=null){if(t===null)return this._insert(e,this.nPages,!1,null);let n=this.getPagePosition(t);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_add_page`,`page_belongs_to_this_view (self, parent)`)),-1;let r=this.pages[n].pinned?this.nPinnedPages-1:n;do if(r++,r>=this.nPages)break;while(isDescendantOfPage(this.pages,this.pages[r].id,t));return this._insert(e,r,!1,t)}insertPage(e,t){return!Number.isInteger(t)||t<this.nPinnedPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`position >= self->n_pinned_pages`)),-1):t>this.nPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`position <= self->n_pages`)),-1):this._insert(e,t,!1,null)}prependPage(e){return this._insert(e,this.nPinnedPages,!1,null)}appendPage(e){return this._insert(e,this.nPages,!1,null)}insertPinnedPage(e,t){return!Number.isInteger(t)||t<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert_pinned`,`position >= 0`)),-1):t>this.nPinnedPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert_pinned`,`position <= self->n_pinned_pages`)),-1):this._insert(e,t,!0,null)}prependPinnedPage(e){return this._insert(e,0,!0,null)}appendPinnedPage(e){return this._insert(e,this.nPinnedPages,!0,null)}_insert(e,t,n,r){if(this.getPagePosition(e.id)>=0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`page id '${e.id}' is unique`)),-1;let i={id:e.id,title:e.title??``,tooltip:e.tooltip??``,icon:e.icon??null,indicatorIcon:e.indicatorIcon??null,loading:e.loading??!1,needsAttention:e.needsAttention??!1,pinned:n,parentId:r,closing:!1,content:e.content};return this._deferSelection=!0,this._stack.insertPage({name:i.id,content:i},t),this._deferSelection=!1,this._emitPages({kind:`attached`,id:i.id,position:t,previousPosition:-1}),this._flushDeferredSelection(),t}setPagePinned(e,t){let n=this.getPagePosition(e);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_page_pinned`,`page_belongs_to_this_view (self, page)`)),-1;let r=this._recordAt(n),i=!!t;if(r.pinned===i)return-1;let a=i?this.nPinnedPages:this.nPinnedPages-1;return r.pinned=i,n!==a&&this._stack.movePage(n,a),this._emitPages({kind:`pinned`,id:e,position:a,previousPosition:n}),a}closePage(e){let t=this._recordOf(e);if(!t)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page`,`page_belongs_to_this_view (self, page)`)),!1;if(t.closing)return!1;t.closing=!0;let n=this._handlers.onClosePage?this._handlers.onClosePage(t):!t.pinned;return n!==`defer`&&this.closePageFinish(e,n),!0}closePageFinish(e,t){let n=this._recordOf(e);return n?n.closing?(n.closing=!1,t?this.detachPage(e)!==null:!1):(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page_finish`,`page->closing`)),!1):(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page_finish`,`page_belongs_to_this_view (self, page)`)),!1)}detachPage(e){let t=this.getPagePosition(e);if(t<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_detach_page`,`page_belongs_to_this_view (self, page)`)),null;let n=this._recordAt(t),r=successorAfterClose(this.pages,e,this.selectedId);r!==null&&r!==this.selectedId&&this.setSelectedPage(r,!1);let i=this.selectedId===e;this._stack.removePage(e);for(let t of this._records())t.parentId===e&&(t.parentId=n.parentId);return i&&(this._selectedId=null,this._emitSelection({selectedId:null,selectedIndex:-1,previousId:e,interactive:!1})),this._emitPages({kind:`detached`,id:e,position:t,previousPosition:t}),n}closeOtherPages(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_other_pages`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=n.length-1;e>=0;e--)e!==t&&this.closePage(n[e])}closePagesBefore(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_pages_before`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=t-1;e>=0;e--)this.closePage(n[e])}closePagesAfter(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_pages_after`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=n.length-1;e>t;e--)this.closePage(n[e])}reorderPage(e,t){let n=this.getPagePosition(e);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,`page_belongs_to_this_view (self, page)`)),!1;let r=this.pages[n].pinned,i=r?0:this.nPinnedPages,a=r?this.nPinnedPages:this.nPages;return!Number.isInteger(t)||t<i||t>=a?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,r?`position < self->n_pinned_pages`:`position >= self->n_pinned_pages`)),!1):n===t?!1:(this._stack.movePage(n,t),this._emitPages({kind:`reordered`,id:e,position:t,previousPosition:n}),!0)}reorderBackward(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):t<=(this.pages[t].pinned?0:this.nPinnedPages)?!1:this.reorderPage(e,t-1)}reorderForward(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):t>=(this.pages[t].pinned?this.nPinnedPages:this.nPages)-1?!1:this.reorderPage(e,t+1)}reorderFirst(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):this.reorderPage(e,this.pages[t].pinned?0:this.nPinnedPages)}reorderLast(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):this.reorderPage(e,(this.pages[t].pinned?this.nPinnedPages:this.nPages)-1)}_reorderMissing(e){return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,`page_belongs_to_this_view (self, '${e}')`)),!1}setPageTitle(e,t){return this._update(e,e=>{let n=t??``;return e.title===n?!1:(e.title=n,!0)})}setPageTooltip(e,t){return this._update(e,e=>{let n=t??``;return e.tooltip===n?!1:(e.tooltip=n,!0)})}setPageIcon(e,t){return this._update(e,e=>e.icon===t?!1:(e.icon=t,!0))}setPageIndicatorIcon(e,t){return this._update(e,e=>e.indicatorIcon===t?!1:(e.indicatorIcon=t,!0))}setPageLoading(e,t){return this._update(e,e=>{let n=!!t;return e.loading===n?!1:(e.loading=n,!0)})}setPageNeedsAttention(e,t){return this._update(e,e=>{let n=!!t;return e.needsAttention===n?!1:(e.needsAttention=n,!0)})}_update(e,t){let n=this.getPagePosition(e);return n<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_page_set_property`,`ADW_IS_TAB_PAGE (self)`)),!1):t(this._recordAt(n))?(this._emitPages({kind:`updated`,id:e,position:n,previousPosition:n}),!0):!1}_records(){return this._stack.pages.map(e=>e.content)}_recordAt(e){return this._stack.pages[e].content}_recordOf(e){let t=this.getPagePosition(e);return t<0?null:this._recordAt(t)}};export{t as DEFAULT_TAB_AUTOHIDE,TabViewState,isDescendantOfPage,successorAfterClose,tabCloseVisible,tabIconState,tabTooltip,tabTooltipIsMarkup,tabsRevealed};
1
+ import"./_virtual/_rolldown/runtime.js";import{ViewStackState as e}from"./view-stack.js";function tabViewItemsChanged(e){switch(e.kind){case`attached`:return{position:e.position,removed:0,added:1};case`detached`:return{position:e.position,removed:1,added:0};case`updated`:return{position:e.position,removed:1,added:1};default:{let t=Math.min(e.position,e.previousPosition),n=Math.abs(e.position-e.previousPosition)+1;return{position:t,removed:n,added:n}}}}const t=!0;function tabsRevealed(e){return e.autohide?e.nPages>1||e.nPinnedPages>=1||e.isTransferringPage:!0}function tabCloseVisible(e){return e.pinned?!1:e.hovering&&e.fullyVisible||e.selected||e.dragging}function tabTooltip(e){return e.tooltip===``?e.title:e.tooltip}function tabTooltipIsMarkup(e){return e.tooltip!==``}function tabIconState(e,t){let n=e.indicatorIcon,r=e.icon;return!e.loading&&e.pinned&&r===null&&(r=t),{icon:r,spinner:e.loading,iconVisible:(r!==null||e.loading)&&(!e.pinned||n===null),indicatorVisible:n!==null}}function isDescendantOfPage(e,t,n){let r=t;for(;r!==null&&r!==n;)r=e.find(e=>e.id===r)?.parentId??null;return r===n}function successorAfterClose(e,t,n){if(t!==n)return n;let r=e.findIndex(e=>e.id===t);if(r<0)return n;let i=e[r].parentId;if(i!==null&&r>0){let t=e[r-1];if(isDescendantOfPage(e,t.id,i))return t.id;let n=e.find(e=>e.id===i);if(n&&t.pinned&&n.pinned)return n.id}return r<e.length-1?e[r+1].id:r>0?e[r-1].id:null}function assertionDiagnostic(e,t){return`${e}: assertion '${t}' failed`}var TabViewState=class{constructor(t={}){this._stack=new e,this._selectionListeners=new Set,this._pagesListeners=new Set,this._diagnostics=[],this._selectedId=null,this._deferSelection=!1,this._deferredSelection=null,this._pagesSource=null,this._pagesView=null,this._handlers=t,this._stack.subscribe(e=>{let t=this._selectedId,n=e.page?.content?.id??null;this._selectedId=n;let r={selectedId:n,selectedIndex:e.index,previousId:t,interactive:e.interactive};this._deferSelection?this._deferredSelection=r:this._emitSelection(r)})}subscribe(e){return this._selectionListeners.add(e),()=>{this._selectionListeners.delete(e)}}subscribePages(e){return this._pagesListeners.add(e),()=>{this._pagesListeners.delete(e)}}_emitSelection(e){for(let t of[...this._selectionListeners])t(e)}_emitPages(e){for(let t of[...this._pagesListeners])t(e)}_flushDeferredSelection(){let e=this._deferredSelection;e&&(this._deferredSelection=null,this._emitSelection(e))}get pages(){let e=this._stack.pages;return(this._pagesSource!==e||this._pagesView===null)&&(this._pagesSource=e,this._pagesView=Object.freeze(e.map(e=>e.content))),this._pagesView}get nPages(){return this._stack.count}get nPinnedPages(){let e=this.pages.findIndex(e=>!e.pinned);return e<0?this.pages.length:e}getNthPage(e){return!Number.isInteger(e)||e<0||e>=this.nPages?null:this.pages[e]}getPagePosition(e){return this._stack.indexOfName(e)}getPage(e){return this._recordOf(e)}isClosing(e){return this._recordOf(e)?.closing??!1}get diagnostics(){return this._diagnostics}get selectedId(){return this._stack.visiblePage?.content?.id??null}get selectedIndex(){return this._stack.visibleIndex}get selectedPage(){return this._stack.visiblePage?.content??null}setSelectedPage(e,t=!0){if(e===null)return this.nPages>0&&this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_selected_page`,`ADW_IS_TAB_PAGE (selected_page)`)),!1;let n=this.getPagePosition(e);return n<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_selected_page`,`page_belongs_to_this_view (self, selected_page)`)),!1):this._stack.setVisibleIndex(n,t)}selectNthPage(e){return this._stack.setVisibleIndex(e,!0)}selectPreviousPage(){let e=this.selectedIndex;return e<=0?!1:this._stack.setVisibleIndex(e-1,!0)}selectNextPage(){let e=this.selectedIndex;return e<0||e>=this.nPages-1?!1:this._stack.setVisibleIndex(e+1,!0)}selectFirstPage(){let e=this.selectedPage;if(!e)return!1;let t=e.pinned,n=this.getNthPage(t?0:this.nPinnedPages);return n===e&&!t&&(n=this.getNthPage(0)),!n||n===e?!1:this.setSelectedPage(n.id)}selectLastPage(){let e=this.selectedPage;if(!e)return!1;let t=e.pinned,n=this.getNthPage((t?this.nPinnedPages:this.nPages)-1);return n===e&&t&&(n=this.getNthPage(this.nPages-1)),!n||n===e?!1:this.setSelectedPage(n.id)}cycleNextPage(){return!this.selectedPage||this.nPages<=1?!1:this.selectNextPage()?!0:this._stack.setVisibleIndex(0,!0)}cyclePreviousPage(){return!this.selectedPage||this.nPages<=1?!1:this.selectPreviousPage()?!0:this._stack.setVisibleIndex(this.nPages-1,!0)}addPage(e,t=null){if(t===null)return this._insert(e,this.nPages,!1,null);let n=this.getPagePosition(t);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_add_page`,`page_belongs_to_this_view (self, parent)`)),-1;let r=this.pages[n].pinned?this.nPinnedPages-1:n;do if(r++,r>=this.nPages)break;while(isDescendantOfPage(this.pages,this.pages[r].id,t));return this._insert(e,r,!1,t)}insertPage(e,t){return!Number.isInteger(t)||t<this.nPinnedPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`position >= self->n_pinned_pages`)),-1):t>this.nPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`position <= self->n_pages`)),-1):this._insert(e,t,!1,null)}prependPage(e){return this._insert(e,this.nPinnedPages,!1,null)}appendPage(e){return this._insert(e,this.nPages,!1,null)}insertPinnedPage(e,t){return!Number.isInteger(t)||t<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert_pinned`,`position >= 0`)),-1):t>this.nPinnedPages?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert_pinned`,`position <= self->n_pinned_pages`)),-1):this._insert(e,t,!0,null)}prependPinnedPage(e){return this._insert(e,0,!0,null)}appendPinnedPage(e){return this._insert(e,this.nPinnedPages,!0,null)}_insert(e,t,n,r){if(this.getPagePosition(e.id)>=0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_insert`,`page id '${e.id}' is unique`)),-1;let i={id:e.id,title:e.title??``,tooltip:e.tooltip??``,icon:e.icon??null,indicatorIcon:e.indicatorIcon??null,loading:e.loading??!1,needsAttention:e.needsAttention??!1,pinned:n,parentId:r,closing:!1,content:e.content};return this._deferSelection=!0,this._stack.insertPage({name:i.id,content:i},t),this._deferSelection=!1,this._emitPages({kind:`attached`,id:i.id,position:t,previousPosition:-1}),this._flushDeferredSelection(),t}setPagePinned(e,t){let n=this.getPagePosition(e);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_set_page_pinned`,`page_belongs_to_this_view (self, page)`)),-1;let r=this._recordAt(n),i=!!t;if(r.pinned===i)return-1;let a=i?this.nPinnedPages:this.nPinnedPages-1;return r.pinned=i,n!==a&&this._stack.movePage(n,a),this._emitPages({kind:`pinned`,id:e,position:a,previousPosition:n}),a}closePage(e){let t=this._recordOf(e);if(!t)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page`,`page_belongs_to_this_view (self, page)`)),!1;if(t.closing)return!1;t.closing=!0;let n=this._handlers.onClosePage?this._handlers.onClosePage(t):!t.pinned;return n!==`defer`&&this.closePageFinish(e,n),!0}closePageFinish(e,t){let n=this._recordOf(e);return n?n.closing?(n.closing=!1,t?this.detachPage(e)!==null:!1):(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page_finish`,`page->closing`)),!1):(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_page_finish`,`page_belongs_to_this_view (self, page)`)),!1)}detachPage(e){let t=this.getPagePosition(e);if(t<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_detach_page`,`page_belongs_to_this_view (self, page)`)),null;let n=this._recordAt(t),r=successorAfterClose(this.pages,e,this.selectedId);r!==null&&r!==this.selectedId&&this.setSelectedPage(r,!1);let i=this.selectedId===e;this._stack.removePage(e);for(let t of this._records())t.parentId===e&&(t.parentId=n.parentId);return i&&(this._selectedId=null,this._emitSelection({selectedId:null,selectedIndex:-1,previousId:e,interactive:!1})),this._emitPages({kind:`detached`,id:e,position:t,previousPosition:t}),n}closeOtherPages(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_other_pages`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=n.length-1;e>=0;e--)e!==t&&this.closePage(n[e])}closePagesBefore(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_pages_before`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=t-1;e>=0;e--)this.closePage(n[e])}closePagesAfter(e){let t=this.getPagePosition(e);if(t<0){this._diagnostics.push(assertionDiagnostic(`adw_tab_view_close_pages_after`,`page_belongs_to_this_view (self, page)`));return}let n=this.pages.map(e=>e.id);for(let e=n.length-1;e>t;e--)this.closePage(n[e])}reorderPage(e,t){let n=this.getPagePosition(e);if(n<0)return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,`page_belongs_to_this_view (self, page)`)),!1;let r=this.pages[n].pinned,i=r?0:this.nPinnedPages,a=r?this.nPinnedPages:this.nPages;return!Number.isInteger(t)||t<i||t>=a?(this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,r?`position < self->n_pinned_pages`:`position >= self->n_pinned_pages`)),!1):n===t?!1:(this._stack.movePage(n,t),this._emitPages({kind:`reordered`,id:e,position:t,previousPosition:n}),!0)}reorderBackward(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):t<=(this.pages[t].pinned?0:this.nPinnedPages)?!1:this.reorderPage(e,t-1)}reorderForward(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):t>=(this.pages[t].pinned?this.nPinnedPages:this.nPages)-1?!1:this.reorderPage(e,t+1)}reorderFirst(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):this.reorderPage(e,this.pages[t].pinned?0:this.nPinnedPages)}reorderLast(e){let t=this.getPagePosition(e);return t<0?this._reorderMissing(e):this.reorderPage(e,(this.pages[t].pinned?this.nPinnedPages:this.nPages)-1)}_reorderMissing(e){return this._diagnostics.push(assertionDiagnostic(`adw_tab_view_reorder_page`,`page_belongs_to_this_view (self, '${e}')`)),!1}setPageTitle(e,t){return this._update(e,e=>{let n=t??``;return e.title===n?!1:(e.title=n,!0)})}setPageTooltip(e,t){return this._update(e,e=>{let n=t??``;return e.tooltip===n?!1:(e.tooltip=n,!0)})}setPageIcon(e,t){return this._update(e,e=>e.icon===t?!1:(e.icon=t,!0))}setPageIndicatorIcon(e,t){return this._update(e,e=>e.indicatorIcon===t?!1:(e.indicatorIcon=t,!0))}setPageLoading(e,t){return this._update(e,e=>{let n=!!t;return e.loading===n?!1:(e.loading=n,!0)})}setPageNeedsAttention(e,t){return this._update(e,e=>{let n=!!t;return e.needsAttention===n?!1:(e.needsAttention=n,!0)})}_update(e,t){let n=this.getPagePosition(e);return n<0?(this._diagnostics.push(assertionDiagnostic(`adw_tab_page_set_property`,`ADW_IS_TAB_PAGE (self)`)),!1):t(this._recordAt(n))?(this._emitPages({kind:`updated`,id:e,position:n,previousPosition:n}),!0):!1}_records(){return this._stack.pages.map(e=>e.content)}_recordAt(e){return this._stack.pages[e].content}_recordOf(e){let t=this.getPagePosition(e);return t<0?null:this._recordAt(t)}};export{t as DEFAULT_TAB_AUTOHIDE,TabViewState,isDescendantOfPage,successorAfterClose,tabCloseVisible,tabIconState,tabTooltip,tabTooltipIsMarkup,tabViewItemsChanged,tabsRevealed};