react-semaphor 0.1.400 → 0.1.402
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/brand-studio/index.cjs +1 -1
- package/dist/brand-studio/index.js +1 -1
- package/dist/chunks/{calendar-preferences-dialog-i3-jBIYS.js → calendar-preferences-dialog-BZgOJhHz.js} +2 -2
- package/dist/chunks/{calendar-preferences-dialog-Ci3rHHgA.js → calendar-preferences-dialog-CGTZM3U8.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-BpwjeJsQ.js → dashboard-briefing-launcher-wimPjqbV.js} +19 -13
- package/dist/chunks/{dashboard-briefing-launcher-DiEpMS9E.js → dashboard-briefing-launcher-wngYnkEs.js} +2 -2
- package/dist/chunks/{dashboard-controls-Bkjpgr3d.js → dashboard-controls-DMz7mAnh.js} +5 -5
- package/dist/chunks/{dashboard-controls-BaUUrvSI.js → dashboard-controls-YqmXJpRK.js} +1 -1
- package/dist/chunks/{dashboard-json-DvULhhN2.js → dashboard-json-CFlCh87B.js} +2 -2
- package/dist/chunks/{dashboard-json-CxNyExRm.js → dashboard-json-smJ7897T.js} +1 -1
- package/dist/chunks/{date-formatter-CzcPZx39.js → date-formatter-BlhBftA9.js} +1 -1
- package/dist/chunks/{edit-dashboard-visual-DBrsgEtL.js → edit-dashboard-visual-Cl1pzC53.js} +3 -3
- package/dist/chunks/{edit-dashboard-visual-DJRPiKdY.js → edit-dashboard-visual-DP0h664h.js} +1 -1
- package/dist/chunks/{index-Drz04wqE.js → index-B6k_ANqY.js} +34206 -33628
- package/dist/chunks/index-CiqoOZXW.js +1346 -0
- package/dist/chunks/{index-DFOb_6HB.js → index-CjzRe2su.js} +3 -3
- package/dist/chunks/{switch-qUw8u-gU.js → switch-CXMExaSF.js} +2384 -2347
- package/dist/chunks/{switch-D2oOmorN.js → switch-oim6Xl36.js} +26 -26
- package/dist/chunks/{use-create-flow-overlay-state-CFJIHt5D.js → use-create-flow-overlay-state-BSUFfv5z.js} +2 -2
- package/dist/chunks/{use-create-flow-overlay-state-DrkYiyQz.js → use-create-flow-overlay-state-BfqXB1zO.js} +1 -1
- package/dist/dashboard/index.cjs +1 -1
- package/dist/dashboard/index.js +1 -1
- package/dist/data-app-builder/index.cjs +1 -1
- package/dist/data-app-builder/index.js +2 -2
- package/dist/format-utils/index.js +2 -2
- package/dist/index.cjs +1 -1
- package/dist/index.js +6 -6
- package/dist/surfboard/index.cjs +1 -1
- package/dist/surfboard/index.js +2 -2
- package/dist/types/dashboard-authoring.d.ts +10 -0
- package/dist/types/dashboard.d.ts +10 -0
- package/dist/types/main.d.ts +18 -3
- package/dist/types/shared.d.ts +10 -0
- package/dist/types/surfboard.d.ts +10 -0
- package/dist/types/types.d.ts +17 -7
- package/package.json +1 -1
- package/dist/chunks/index-BepF6hoa.js +0 -1346
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),m=require("react"),d=require("../chunks/switch-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),m=require("react"),d=require("../chunks/switch-oim6Xl36.js"),A=require("../chunks/index-DRlMUglg.js"),J=require("../chunks/x-B6ghREd2.js");require("../chunks/analyze-result-contract-S8u7CcPL.js");const U=require("../chunks/palette-C4KTXOug.js"),be=require("../chunks/braces-D2tStQjF.js"),fe=require("../chunks/save-C__QggEE.js"),me=require("../chunks/layout-grid-C0OI-MRn.js");/**
|
|
2
2
|
* @license lucide-react v0.453.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as d, jsx as r, Fragment as ce } from "react/jsx-runtime";
|
|
2
2
|
import m from "react";
|
|
3
|
-
import { c as q, P as ge, a as be, B as C, b as fe, U as De, C as Ie, R as me, e as le, S as se, d as Je, T as je, G as Le, H as U, I as $e, J as M, K as _e, M as Ve, N as Ue, O as Me, L as E, Q as K, V as Q, W as ee, X as he, Y as re, Z as oe, _ as ke, $ as xe, a0 as ye, a1 as ve, a2 as Ce, a3 as Ge } from "../chunks/switch-
|
|
3
|
+
import { c as q, P as ge, a as be, B as C, b as fe, U as De, C as Ie, R as me, e as le, S as se, d as Je, T as je, G as Le, H as U, I as $e, J as M, K as _e, M as Ve, N as Ue, O as Me, L as E, Q as K, V as Q, W as ee, X as he, Y as re, Z as oe, _ as ke, $ as xe, a0 as ye, a1 as ve, a2 as Ce, a3 as Ge } from "../chunks/switch-CXMExaSF.js";
|
|
4
4
|
import { r as We, v as He, A as Xe, a as Ye, p as Ze } from "../chunks/index-CJdxSyQq.js";
|
|
5
5
|
import { c as ae, X as qe } from "../chunks/x-CXDkqdur.js";
|
|
6
6
|
import "../chunks/analyze-result-contract-BUgK3759.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as r, jsxs as s, Fragment as X } from "react/jsx-runtime";
|
|
2
2
|
import ee, { useState as h, useCallback as F, useEffect as ae, useMemo as H } from "react";
|
|
3
|
-
import { u as re, b as te, c as se, d as ne, e as le, f as oe, R as W, g as O, C as ie, h as ce, i as de, j as ue, k as me, l as _, m as R, n as fe, o as he, p as N } from "./index-
|
|
4
|
-
import { c as S, L as G, P as pe, a as ge, B as j, b as ve, d as V, e as be } from "./switch-
|
|
3
|
+
import { u as re, b as te, c as se, d as ne, e as le, f as oe, R as W, g as O, C as ie, h as ce, i as de, j as ue, k as me, l as _, m as R, n as fe, o as he, p as N } from "./index-B6k_ANqY.js";
|
|
4
|
+
import { c as S, L as G, P as pe, a as ge, B as j, b as ve, d as V, e as be } from "./switch-CXMExaSF.js";
|
|
5
5
|
import "./x-CXDkqdur.js";
|
|
6
6
|
import "./analyze-result-contract-BUgK3759.js";
|
|
7
7
|
function we(n = {}) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),l=require("react"),t=require("./index-
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),l=require("react"),t=require("./index-CiqoOZXW.js"),o=require("./switch-oim6Xl36.js");require("./x-B6ghREd2.js");require("./analyze-result-contract-S8u7CcPL.js");function G(n={}){var y,P,z,A;const{authToken:d,tokenProps:a}=t.useSemaphorContext(),x=n.enabled??!0,m=(d==null?void 0:d.accessToken)??null,f=(a==null?void 0:a.apiServiceUrl)??null,[L,C]=l.useState(!1),[j,b]=l.useState(!1),[h,g]=l.useState(!1),[N,c]=l.useState(null),[v,S]=l.useState(null),k=v||{tz:((P=(y=a==null?void 0:a.params)==null?void 0:y.calendarContext)==null?void 0:P.tz)||null,weekStart:((A=(z=a==null?void 0:a.params)==null?void 0:z.calendarContext)==null?void 0:A.weekStart)??null},p=l.useCallback(async()=>{if(!(!x||!m||!f)){C(!0),c(null);try{const i=await fetch(`${f}/v1/user-preferences/calendar`,{method:"GET",headers:{Authorization:`Bearer ${m}`}});if(!i.ok){const u=await i.json().catch(()=>({}));throw new Error(u.error||"Failed to fetch preferences")}const r=await i.json();S({tz:r.tz,weekStart:r.weekStart,source:r.source,isInherited:r.isInherited,userHasPrefs:r.userHasPrefs,inherited:r.inherited})}catch(i){const r=i instanceof Error?i.message:"Unknown error";c(r)}finally{C(!1)}}},[m,f,x]);l.useEffect(()=>{x&&p()},[x,p]);const T=l.useCallback(async i=>{if(!m||!f)return c("Not authenticated"),!1;b(!0),c(null);try{const r=await fetch(`${f}/v1/user-preferences/calendar`,{method:"PATCH",headers:{"Content-Type":"application/json",Authorization:`Bearer ${m}`},body:JSON.stringify(i)});if(!r.ok){const u=await r.json().catch(()=>({}));throw new Error(u.error||"Failed to update preferences")}return await p(),!0}catch(r){const u=r instanceof Error?r.message:"Unknown error";return c(u),!1}finally{b(!1)}},[m,f,p]),w=l.useCallback(async()=>{if(!m||!f)return c("Not authenticated"),!1;g(!0),c(null);try{const i=await fetch(`${f}/v1/user-preferences/calendar`,{method:"DELETE",headers:{Authorization:`Bearer ${m}`}});if(!i.ok){const u=await i.json().catch(()=>({}));throw new Error(u.error||"Failed to clear preferences")}const r=await i.text();if(r)try{const u=JSON.parse(r);return S({tz:u.tz,weekStart:u.weekStart,source:u.source,isInherited:u.isInherited??!0,userHasPrefs:!1,inherited:u.inherited}),!0}catch{}return await p(),!0}catch(i){const r=i instanceof Error?i.message:"Unknown error";return c(r),!1}finally{g(!1)}},[m,f,p]);return{preferences:k,isLoading:L,isSaving:j,isClearing:h,error:N,updatePreferences:T,clearPreferences:w,refetch:p}}const E=[{value:"America/New_York",label:"Eastern Time (US & Canada)"},{value:"America/Chicago",label:"Central Time (US & Canada)"},{value:"America/Denver",label:"Mountain Time (US & Canada)"},{value:"America/Los_Angeles",label:"Pacific Time (US & Canada)"},{value:"America/Phoenix",label:"Arizona"},{value:"America/Anchorage",label:"Alaska"},{value:"Pacific/Honolulu",label:"Hawaii"},{value:"Europe/London",label:"London"},{value:"Europe/Paris",label:"Paris, Berlin, Rome"},{value:"Asia/Tokyo",label:"Tokyo"},{value:"Asia/Shanghai",label:"Beijing, Shanghai"},{value:"Asia/Kolkata",label:"Mumbai, New Delhi"},{value:"Australia/Sydney",label:"Sydney"},{value:"UTC",label:"UTC"}],M=[{value:0,label:"Sunday"},{value:1,label:"Monday"},{value:6,label:"Saturday"}],H="text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground";function W(){try{const n=Intl;if(n.supportedValuesOf)return n.supportedValuesOf("timeZone")}catch{}return E.map(n=>n.value)}function _(n){switch(n){case"tenant":return"tenant";case"organization":return"organization";case"system":return"system";default:return"default"}}function O(n){const d=E.find(a=>a.value===n);return d?d.label:n}function q(n){const d=M.find(a=>a.value===n);return d?d.label:String(n)}function V({open:n,onOpenChange:d}){var D,U,F;const{preferences:a,isLoading:x,isSaving:m,isClearing:f,updatePreferences:L,clearPreferences:C}=G({enabled:n}),j=a.tz||((D=a.inherited)==null?void 0:D.tz)||Intl.DateTimeFormat().resolvedOptions().timeZone,b=a.weekStart??((U=a.inherited)==null?void 0:U.weekStart)??1,[h,g]=l.useState(!a.userHasPrefs),[N,c]=l.useState(!1),[v,S]=l.useState(j),[k,p]=l.useState(b),[T,w]=l.useState(!1),y=l.useMemo(()=>W(),[]),P=l.useMemo(()=>y.filter(s=>!E.some(R=>R.value===s)),[y]),z=l.useMemo(()=>O(v),[v]),A=a.inherited?O(a.inherited.tz):"UTC",i=a.inherited?q(a.inherited.weekStart):"Monday",r=_((F=a.inherited)==null?void 0:F.source);l.useEffect(()=>{if(!n){c(!1);return}N||(a.userHasPrefs!==void 0&&g(!a.userHasPrefs),S(j),p(b))},[n,N,a.userHasPrefs,j,b]);const u=async()=>{if(x){t.ue.error("Preferences are still loading. Please try again.");return}h?await C()?(t.ue.success("Now using default settings. Please refresh the page to apply changes.",{duration:5e3}),d(!1)):t.ue.error("Failed to save preferences. Please try again."):await L({tz:v,weekStart:k})?(t.ue.success("Preferences saved. Please refresh the page to apply changes.",{duration:5e3}),d(!1)):t.ue.error("Failed to save preferences. Please try again.")},$=()=>{d(!1)},I=m||f,B=I||x;return e.jsx(t.Dialog,{open:n,onOpenChange:d,children:e.jsxs(t.DialogContent,{className:"rounded-control border-border/60 sm:max-w-[440px] sm:rounded-control",children:[e.jsxs(t.DialogHeader,{children:[e.jsx(t.DialogTitle,{className:"text-[15px]",children:"Calendar preferences"}),e.jsx(t.DialogDescription,{className:"text-[13px] leading-5",children:"Set your timezone and week-start for date calculations and displays."})]}),e.jsxs("div",{className:"space-y-4 py-1",children:[e.jsxs(t.RadioGroup,{value:h?"defaults":"custom",onValueChange:s=>{c(!0),g(s==="defaults")},className:"space-y-0.5",children:[e.jsxs("label",{htmlFor:"mode-defaults",className:o.cn("flex cursor-pointer items-start gap-2 rounded-control px-2 py-1.5 hover:bg-muted/50",h&&"bg-muted/50"),onClick:()=>{c(!0),g(!0)},children:[e.jsx(t.RadioGroupItem,{value:"defaults",id:"mode-defaults",className:"mt-0.5"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("p",{className:"text-[13px] font-medium text-foreground",children:["Use ",r," defaults"]}),e.jsxs("p",{className:"text-[12px] text-muted-foreground",children:[A,", week starts ",i]})]})]}),e.jsxs("label",{htmlFor:"mode-custom",className:o.cn("flex cursor-pointer items-start gap-2 rounded-control px-2 py-1.5 hover:bg-muted/50",!h&&"bg-muted/50"),onClick:()=>{c(!0),g(!1)},children:[e.jsx(t.RadioGroupItem,{value:"custom",id:"mode-custom",className:"mt-0.5"}),e.jsx("p",{className:"flex-1 text-[13px] font-medium text-foreground",children:"Use custom settings"})]})]}),e.jsxs("div",{className:o.cn("space-y-4 border-t border-border/60 pt-4 transition-opacity",h&&"pointer-events-none opacity-50"),children:[e.jsxs("div",{className:"space-y-1.5",children:[e.jsx(o.Label,{className:H,children:"Timezone"}),e.jsxs(o.Popover,{open:T,onOpenChange:w,modal:!0,children:[e.jsx(o.PopoverTrigger,{asChild:!0,children:e.jsxs(o.Button,{variant:"outline",size:"xs",role:"combobox","aria-expanded":T,className:"w-full justify-between text-[12px] font-normal",disabled:h,children:[e.jsx("span",{className:"truncate",children:z}),e.jsx(t.ChevronsUpDown,{className:"ml-2 h-3.5 w-3.5 shrink-0 opacity-50"})]})}),e.jsx(o.PopoverContent,{className:"z-50 w-[--radix-popover-trigger-width] p-0",align:"start",children:e.jsxs(t.Command,{className:"overflow-visible",children:[e.jsx(t.CommandInput,{placeholder:"Search timezones…"}),e.jsxs(t.CommandList,{children:[e.jsx(t.CommandEmpty,{children:"No timezone found."}),e.jsx(t.CommandGroup,{heading:"Common",children:E.map(s=>e.jsxs(t.CommandItem,{value:`${s.value} ${s.label}`,onSelect:()=>{c(!0),S(s.value),w(!1)},children:[e.jsx(o.Check,{className:o.cn("h-3.5 w-3.5",v===s.value?"opacity-100":"opacity-0")}),e.jsx("span",{className:"flex-1",children:s.label}),e.jsx("span",{className:"text-[11px] text-muted-foreground",children:s.value})]},s.value))}),e.jsx(t.CommandSeparator,{}),e.jsx(t.CommandGroup,{heading:"All timezones",children:P.map(s=>e.jsxs(t.CommandItem,{value:s,onSelect:()=>{c(!0),S(s),w(!1)},children:[e.jsx(o.Check,{className:o.cn("h-3.5 w-3.5",v===s?"opacity-100":"opacity-0")}),s]},s))})]})]})})]})]}),e.jsxs("div",{className:"space-y-1.5",children:[e.jsx(o.Label,{className:H,children:"Week starts on"}),e.jsx(t.RadioGroup,{value:String(k),onValueChange:s=>{c(!0),p(Number(s))},className:"flex gap-4",disabled:h,children:M.map(s=>e.jsxs("label",{htmlFor:`week-start-${s.value}`,className:o.cn("flex cursor-pointer items-center gap-2 text-[13px]",h&&"cursor-not-allowed"),children:[e.jsx(t.RadioGroupItem,{value:String(s.value),id:`week-start-${s.value}`,disabled:h}),s.label]},s.value))})]})]})]}),e.jsxs(t.DialogFooter,{children:[e.jsx(o.Button,{variant:"outline",size:"xs",onClick:$,disabled:I,children:"Cancel"}),e.jsx(o.Button,{size:"xs",onClick:u,disabled:B,children:I?e.jsxs(e.Fragment,{children:[e.jsx(o.LoaderCircle,{className:"h-3.5 w-3.5 animate-spin"}),"Saving…"]}):"Save"})]})]})})}exports.CalendarPreferencesDialog=V;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsx as t, jsxs as s, Fragment as le } from "react/jsx-runtime";
|
|
2
2
|
import bo, { useState as S, useEffect as fe, useMemo as O, useContext as xo, useRef as Me, useCallback as ye } from "react";
|
|
3
|
-
import { b as rt, c as at, e as st, aF as ka, bs as yo, bO as vo, bP as No, ar as Rt, bC as Sa, aW as gt, J as wo, A as Co, bQ as ko, ah as Jt, ak as Qt, al as Xt, am as Yt, an as Zt, ao as en, ap as tn, aq as Yn, aV as nn, p as be, bR as So, bS as Do, bT as In, bD as rn, bE as an, bU as Zn, bF as sn, bG as De, av as Eo, b8 as jt, bV as Da, br as $n, d as bt, f as xt, bW as Ao, o as Ea, aE as Io, aT as Aa, bX as To, aU as _n, y as Lo, ae as Fo, ax as Ro, u as Pt, a0 as mt, ab as er, a7 as Ia, a8 as tr, a1 as Ta, a6 as Po, ad as Bo, bJ as Mo, bY as Vo, b4 as Oo, a9 as qr, x as zt, a3 as Uo, bZ as $o, b_ as _o, b$ as jo, c0 as zo, c1 as Ko, c2 as qo, c3 as Ho, c4 as Go, c5 as La, c6 as Wo, c7 as Jo, c8 as Qo, c9 as Xo, ca as Yo, ay as yt, cb as Zo, bH as Fa, cc as ei, cd as ti, ce as ni, cf as ri, cg as ai, ch as si, ci as oi, cj as Ra, ck as ii, cl as li, cm as Pa, cn as Ba, co as Ma, cp as di, cq as ci, be as Va, bp as ui, bm as mi, cr as hi, aw as Oa, cs as pi, ct as fi, cu as gi, cv as bi, cw as jn, cx as xi, cy as yi, cz as Ua, cA as nr, cB as vi, cC as Ni, cD as $a, cE as wi, cF as Ci, cG as ki, cH as _a, as as Si, cI as Di, cJ as Ei, cK as Ai, cL as Ii, cM as Ti, cN as Li, cO as Fi } from "./index-
|
|
4
|
-
import { B as Z, L as Lt, Z as zn, e as se, N as ja, d as je, c as v, M as za, E as vt, u as Q, A as Nt, aF as Hr, a6 as Ka, F as qa, S as rr, P as $e, a as ot, b as it, aG as Ri, aH as Pi, aD as Ha, aI as Ga, _ as Ye, $ as Ze, a0 as et, a1 as tt, a2 as xe, aJ as Wa, aK as Ja, X as nt, T as Bi, G as Mi, H as Gr, aL as Vi } from "./switch-
|
|
3
|
+
import { b as rt, c as at, e as st, aF as ka, bs as yo, bO as vo, bP as No, ar as Rt, bC as Sa, aW as gt, J as wo, A as Co, bQ as ko, ah as Jt, ak as Qt, al as Xt, am as Yt, an as Zt, ao as en, ap as tn, aq as Yn, aV as nn, p as be, bR as So, bS as Do, bT as In, bD as rn, bE as an, bU as Zn, bF as sn, bG as De, av as Eo, b8 as jt, bV as Da, br as $n, d as bt, f as xt, bW as Ao, o as Ea, aE as Io, aT as Aa, bX as To, aU as _n, y as Lo, ae as Fo, ax as Ro, u as Pt, a0 as mt, ab as er, a7 as Ia, a8 as tr, a1 as Ta, a6 as Po, ad as Bo, bJ as Mo, bY as Vo, b4 as Oo, a9 as qr, x as zt, a3 as Uo, bZ as $o, b_ as _o, b$ as jo, c0 as zo, c1 as Ko, c2 as qo, c3 as Ho, c4 as Go, c5 as La, c6 as Wo, c7 as Jo, c8 as Qo, c9 as Xo, ca as Yo, ay as yt, cb as Zo, bH as Fa, cc as ei, cd as ti, ce as ni, cf as ri, cg as ai, ch as si, ci as oi, cj as Ra, ck as ii, cl as li, cm as Pa, cn as Ba, co as Ma, cp as di, cq as ci, be as Va, bp as ui, bm as mi, cr as hi, aw as Oa, cs as pi, ct as fi, cu as gi, cv as bi, cw as jn, cx as xi, cy as yi, cz as Ua, cA as nr, cB as vi, cC as Ni, cD as $a, cE as wi, cF as Ci, cG as ki, cH as _a, as as Si, cI as Di, cJ as Ei, cK as Ai, cL as Ii, cM as Ti, cN as Li, cO as Fi } from "./index-B6k_ANqY.js";
|
|
4
|
+
import { B as Z, L as Lt, Z as zn, e as se, N as ja, d as je, c as v, M as za, E as vt, u as Q, A as Nt, aF as Hr, a6 as Ka, F as qa, S as rr, P as $e, a as ot, b as it, aG as Ri, aH as Pi, aD as Ha, aI as Ga, _ as Ye, $ as Ze, a0 as et, a1 as tt, a2 as xe, aJ as Wa, aK as Ja, X as nt, T as Bi, G as Mi, H as Gr, aL as Vi } from "./switch-CXMExaSF.js";
|
|
5
5
|
import { L as ar } from "./layout-grid-CiubineE.js";
|
|
6
6
|
import { c as Pe, X as Ae, C as Ge } from "./x-CXDkqdur.js";
|
|
7
|
-
import { u as sr, V as Oi, E as Wr, a as Jr, b as Ui, c as $i, L as _i, d as ji, e as Qa, C as Xa, f as zi, R as Ki, S as qi } from "./use-create-flow-overlay-state-
|
|
7
|
+
import { u as sr, V as Oi, E as Wr, a as Jr, b as Ui, c as $i, L as _i, d as ji, e as Qa, C as Xa, f as zi, R as Ki, S as qi } from "./use-create-flow-overlay-state-BSUFfv5z.js";
|
|
8
8
|
import "./analyze-result-contract-BUgK3759.js";
|
|
9
9
|
import { S as Hi, M as Gi, a as Bt, C as Kn } from "./search-BHsQIWBV.js";
|
|
10
|
-
import { l as Qr } from "./date-formatter-
|
|
10
|
+
import { l as Qr } from "./date-formatter-BlhBftA9.js";
|
|
11
11
|
import "./index-CJdxSyQq.js";
|
|
12
12
|
import "react-dom";
|
|
13
13
|
/**
|
|
@@ -2837,7 +2837,10 @@ function Wl(e) {
|
|
|
2837
2837
|
const n = {
|
|
2838
2838
|
...fs(void 0, e.format)
|
|
2839
2839
|
}, r = e.runtime;
|
|
2840
|
-
return r != null && r.theme && (n.theme = r.theme), e.option.kind === "dashboard" && (n.sheetSelection = "all"), e.option.kind === "dashboard_sheet" && (n.sheetSelection = "current", n.currentSheetId = e.option.sheetId, n.currentSheetName = e.option.title.replace(/\sPDF$/, "")), e.option.kind === "document_sheet" && (n.currentSheetId = e.option.sheetId, n.currentSheetName = e.option.title.replace(/\sPDF$/, "")), e.option.kind === "card" && (n.selectedSheetId = e.option.sheetId, n.cardType = e.option.cardType, e.option.cardControlDefinitions && (n.cardControlDefinitions = de(e.option.cardControlDefinitions)), e.option.controlBindings && (n.controlBindings = de(e.option.controlBindings)), e.option.tablePreferences && (n.tablePreferences = de(e.option.tablePreferences))), Jl({ settings: n, option: e.option, runtime: r }), n.includeFilters !== !1 && (n.filterLine = ed(
|
|
2840
|
+
return r != null && r.theme && (n.theme = r.theme), e.option.kind === "dashboard" && (n.sheetSelection = "all"), e.option.kind === "dashboard_sheet" && (n.sheetSelection = "current", n.currentSheetId = e.option.sheetId, n.currentSheetName = e.option.title.replace(/\sPDF$/, "")), e.option.kind === "document_sheet" && (n.currentSheetId = e.option.sheetId, n.currentSheetName = e.option.title.replace(/\sPDF$/, "")), e.option.kind === "card" && (n.selectedSheetId = e.option.sheetId, n.cardType = e.option.cardType, e.option.cardControlDefinitions && (n.cardControlDefinitions = de(e.option.cardControlDefinitions)), e.option.controlBindings && (n.controlBindings = de(e.option.controlBindings)), e.option.tablePreferences && (n.tablePreferences = de(e.option.tablePreferences))), Jl({ settings: n, option: e.option, runtime: r }), n.includeFilters !== !1 && (n.filterLine = ed(
|
|
2841
|
+
n.filterValues,
|
|
2842
|
+
r == null ? void 0 : r.timezone
|
|
2843
|
+
)), n;
|
|
2841
2844
|
}
|
|
2842
2845
|
function Jl(e) {
|
|
2843
2846
|
const { settings: n, option: r, runtime: a } = e;
|
|
@@ -2853,7 +2856,9 @@ function Jl(e) {
|
|
|
2853
2856
|
selectedSheetId: i,
|
|
2854
2857
|
sheetSelection: o,
|
|
2855
2858
|
dashboardControlValues: a.controlValues,
|
|
2856
|
-
cardControlValuesMap: a.cardControlValuesMap
|
|
2859
|
+
cardControlValuesMap: a.cardControlValuesMap,
|
|
2860
|
+
semanticExecutionPayload: a.semanticExecutionPayload,
|
|
2861
|
+
timezone: a.timezone
|
|
2857
2862
|
});
|
|
2858
2863
|
n.sheetFilterValues = de(l.filterValues), n.filterValues = de(l.filterValues), n.controlValues = de(l.controlValues), a.controlDefinitions && (n.controlDefinitions = de(a.controlDefinitions));
|
|
2859
2864
|
const c = Xl({
|
|
@@ -2893,7 +2898,8 @@ function Ql(e) {
|
|
|
2893
2898
|
},
|
|
2894
2899
|
dashboardControls: a.dashboardControls || a.controlDefinitions,
|
|
2895
2900
|
dashboardControlValues: a.controlValues,
|
|
2896
|
-
cardControlValuesMap: a.cardControlValuesMap
|
|
2901
|
+
cardControlValuesMap: a.cardControlValuesMap,
|
|
2902
|
+
timezone: a.timezone
|
|
2897
2903
|
});
|
|
2898
2904
|
c ? (n.filterValues = de(c.queryContext.cardFilterValues), n.controlValues = de(c.queryContext.controlValues), n.controlDefinitions = de(
|
|
2899
2905
|
c.queryContext.controlDefinitions
|
|
@@ -2921,7 +2927,7 @@ function Xl(e) {
|
|
|
2921
2927
|
const { option: n, runtime: r } = e, a = r.dashboard;
|
|
2922
2928
|
if (!((c = a == null ? void 0 : a.inputs) != null && c.length))
|
|
2923
2929
|
return;
|
|
2924
|
-
const o = (/* @__PURE__ */ new Date()).toISOString(), i = ps();
|
|
2930
|
+
const o = (/* @__PURE__ */ new Date()).toISOString(), i = r.timezone || ps();
|
|
2925
2931
|
if (n.kind === "document_sheet" && n.sheetId)
|
|
2926
2932
|
return Ra({
|
|
2927
2933
|
dashboard: a,
|
|
@@ -2986,7 +2992,7 @@ function Yl(e) {
|
|
|
2986
2992
|
cardControlValuesMap: r.cardControlValuesMap
|
|
2987
2993
|
},
|
|
2988
2994
|
generatedAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
2989
|
-
timezone: ps()
|
|
2995
|
+
timezone: r.timezone || ps()
|
|
2990
2996
|
}).snapshot;
|
|
2991
2997
|
}
|
|
2992
2998
|
function Zl(e, n, r) {
|
|
@@ -2999,13 +3005,13 @@ function Zl(e, n, r) {
|
|
|
2999
3005
|
function ps() {
|
|
3000
3006
|
return typeof Intl < "u" ? Intl.DateTimeFormat().resolvedOptions().timeZone : void 0;
|
|
3001
3007
|
}
|
|
3002
|
-
function ed(e) {
|
|
3008
|
+
function ed(e, n) {
|
|
3003
3009
|
if (!Array.isArray(e))
|
|
3004
3010
|
return "";
|
|
3005
|
-
const
|
|
3006
|
-
(
|
|
3011
|
+
const r = e.filter(
|
|
3012
|
+
(a) => !!a && typeof a == "object" && typeof a.name == "string"
|
|
3007
3013
|
);
|
|
3008
|
-
return ai(n);
|
|
3014
|
+
return ai(r, { timezone: n });
|
|
3009
3015
|
}
|
|
3010
3016
|
function fs(e, n) {
|
|
3011
3017
|
return n === "csv" ? { ...Kl, ...e } : { ...zl, ...e };
|