@veeqo/transfigure 1.2.7 → 1.2.8
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/hooks/useViewCountsHook/useViewCountsHook.d.ts +2 -2
- package/dist/index100.cjs +1 -1
- package/dist/index100.js +48 -9
- package/dist/index101.cjs +1 -19
- package/dist/index101.js +28 -23
- package/dist/index103.cjs +1 -1
- package/dist/index103.js +7 -15
- package/dist/index104.cjs +1 -1
- package/dist/index104.js +22 -36
- package/dist/index105.cjs +1 -1
- package/dist/index105.js +17 -28
- package/dist/index106.cjs +1 -1
- package/dist/index106.js +15 -24
- package/dist/index109.cjs +1 -1
- package/dist/index109.js +19 -2
- package/dist/index11.cjs +1 -1
- package/dist/index11.js +1 -1
- package/dist/index110.cjs +1 -1
- package/dist/index110.js +7 -18
- package/dist/index111.cjs +1 -1
- package/dist/index111.js +63 -7
- package/dist/index112.cjs +1 -1
- package/dist/index112.js +26 -60
- package/dist/index113.cjs +1 -1
- package/dist/index113.js +2 -30
- package/dist/index114.cjs +1 -13
- package/dist/index114.js +33 -14
- package/dist/index115.cjs +13 -1
- package/dist/index115.js +14 -33
- package/dist/index118.cjs +1 -7
- package/dist/index118.js +63 -10
- package/dist/index119.cjs +1 -1
- package/dist/index119.js +42 -58
- package/dist/index120.cjs +7 -1
- package/dist/index120.js +10 -47
- package/dist/index13.cjs +1 -1
- package/dist/index13.js +1 -1
- package/dist/index17.cjs +1 -1
- package/dist/index17.js +1 -1
- package/dist/index19.cjs +1 -1
- package/dist/index19.js +1 -1
- package/dist/index22.cjs +1 -1
- package/dist/index22.js +1 -1
- package/dist/index30.cjs +1 -1
- package/dist/index30.js +1 -1
- package/dist/index31.cjs +1 -1
- package/dist/index31.js +1 -1
- package/dist/index34.cjs +1 -1
- package/dist/index34.js +1 -1
- package/dist/index36.cjs +1 -1
- package/dist/index36.js +3 -3
- package/dist/index39.cjs +1 -1
- package/dist/index39.js +1 -1
- package/dist/index41.cjs +1 -1
- package/dist/index41.js +1 -1
- package/dist/index47.cjs +1 -1
- package/dist/index47.js +2 -2
- package/dist/index78.cjs +1 -1
- package/dist/index78.js +11 -10
- package/dist/index79.cjs +1 -1
- package/dist/index79.js +3 -2
- package/dist/index80.cjs +1 -1
- package/dist/index80.js +1 -1
- package/dist/index84.cjs +1 -1
- package/dist/index84.js +1 -1
- package/dist/index85.cjs +1 -1
- package/dist/index85.js +1 -1
- package/dist/index86.cjs +1 -1
- package/dist/index86.js +5 -41
- package/dist/index87.cjs +1 -1
- package/dist/index87.js +2 -9
- package/dist/index88.cjs +1 -1
- package/dist/index88.js +41 -2
- package/dist/index89.cjs +1 -1
- package/dist/index89.js +8 -4
- package/dist/index90.cjs +1 -1
- package/dist/index90.js +7 -7
- package/dist/index92.cjs +1 -1
- package/dist/index92.js +13 -7
- package/dist/index93.cjs +104 -1
- package/dist/index93.js +119 -17
- package/dist/index94.cjs +1 -1
- package/dist/index94.js +68 -13
- package/dist/index95.cjs +1 -104
- package/dist/index95.js +28 -119
- package/dist/index96.cjs +1 -1
- package/dist/index96.js +2 -68
- package/dist/index97.cjs +1 -1
- package/dist/index97.js +39 -27
- package/dist/index98.cjs +1 -1
- package/dist/index98.js +11 -2
- package/dist/index99.cjs +19 -1
- package/dist/index99.js +24 -41
- package/dist/types.d.ts +2 -24
- package/package.json +1 -1
package/dist/index30.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),g=require("mobx-react"),u=require("@veeqo/ui"),h=require("lodash/debounce"),n=require("./index49.cjs"),j=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),g=require("mobx-react"),u=require("@veeqo/ui"),h=require("lodash/debounce"),n=require("./index49.cjs"),j=require("./index87.cjs"),m=require("./index8.cjs"),y=require("./index61.cjs"),k=r=>r&&r.__esModule?r:{default:r},B=k(h),v=g.observer(({fields:r,groupId:c})=>{const{FILTERS_DEBOUCE_INTERVAL_MS:S}=m.useBusinessLogic(),{Filters:{getFiltersForGroup:p,setFilter:a,clearFiltersForGroup:V}}=y.useStores(),_=p(c),[d,F]=o.useState(_),[E,x]=o.useState({}),C=o.useCallback(B.default((e,t)=>{a(e,t)},S),[a]),q=(e,t)=>{const s={...d,[e]:t},i={...E},T=Object.entries(s).every(([b,M])=>j.isTextFilterValid(String(M))?(i[b]="",!0):(i[b]=n.MIN_SEARCH_ERROR_MESSAGE,!1));F(s),x(i),T&&C(e,t)},R=()=>{const e=r.reduce((t,s)=>({...t,[s.id]:""}),{});F(e),V(c)};return l.jsxs(u.FlexCol,{children:[l.jsx(u.Button,{variant:"link",onClick:R,children:"Clear"}),r.map(e=>{let t;switch(e.filterType){case n.FilterChoiceValue.NUMBER:t="number";break;case n.FilterChoiceValue.TEXT:t="text";break}return l.jsx(u.TextField,{type:t,value:d[e.id],error:E[e.id],label:e.label,onChange:s=>q(e.id,s)},e.id)})]})});exports.MultipleFieldFilter=v;
|
package/dist/index30.js
CHANGED
|
@@ -4,7 +4,7 @@ import { observer as _ } from "mobx-react";
|
|
|
4
4
|
import { FlexCol as k, Button as M, TextField as g } from "@veeqo/ui";
|
|
5
5
|
import y from "lodash/debounce";
|
|
6
6
|
import { FilterChoiceValue as F, MIN_SEARCH_ERROR_MESSAGE as B } from "./index49.js";
|
|
7
|
-
import { isTextFilterValid as G } from "./
|
|
7
|
+
import { isTextFilterValid as G } from "./index87.js";
|
|
8
8
|
import { useBusinessLogic as j } from "./index8.js";
|
|
9
9
|
import { useStores as v } from "./index61.js";
|
|
10
10
|
const q = _(({ fields: s, groupId: i }) => {
|
package/dist/index31.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),d=require("react"),_=require("mobx-react"),j=require("lodash/debounce"),r=require("@veeqo/ui"),L=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),d=require("react"),_=require("mobx-react"),j=require("lodash/debounce"),r=require("@veeqo/ui"),L=require("./index114.cjs"),R=require("./index69.cjs"),p=require("./index8.cjs"),y=require("./index61.cjs"),v=i=>i&&i.__esModule?i:{default:i},k=v(j),I=_.observer(({field:i})=>{var M;const{FILTERS_DEBOUCE_INTERVAL_MS:f}=p.useBusinessLogic(),{Filters:{numberRangeFilters:u,setNumberRangeFilter:x,clearNumberRangeFilter:F}}=y.useStores(),e=u.get(i.id),[o,g]=d.useState({gte:(e==null?void 0:e.gte)??0,lte:(e==null?void 0:e.lte)??100});if(!((M=i.options)!=null&&M.length))return null;const b=()=>{const l=new R.NumberRangeFilter({filterId:i.id});return u.set(i.id,l),l},c=d.useCallback(k.default(({numberRange:l,lte:t,gte:n})=>{x({numberRange:l,lte:t,gte:n})},f),[x]),h=()=>{g({gte:0,lte:100}),F(i.id)},S=(l,t)=>{let n=new R.NumberRangeFilter({filterId:i.id});if(e||(n=b()),!Array.isArray(t)||t.length!==2)return;const[s,m]=t;g({gte:s,lte:m}),c(e?{numberRange:e,lte:m,gte:s}:{numberRange:n,lte:m,gte:s})},N=l=>{if(e||b(),!e)return;const t=Number(l);if(t>e.lteMax)return;let{lte:n}=e,{gte:s}=e;t>=e.gteMin&&t<=e.lteMax&&(s=t),(!e.lte||t>=e.lte)&&(n=e.lteMax),g({gte:s,lte:n}),c({numberRange:e,lte:n,gte:s})},C=l=>{if(e||b(),!e)return;const t=Number(l);if(t<e.gteMin)return;let{lte:n}=e,{gte:s}=e;t>=e.gteMin&&t<=e.lteMax&&(n=t),(!e.gte||t<=e.gte)&&(s=e.gteMin),g({gte:s,lte:n}),c({numberRange:e,lte:n,gte:s})},q=[o.gte,o.lte];return a.jsxs(r.Stack,{spacing:"xs",alignX:"stretch",children:[a.jsx(r.Button,{variant:"link",onClick:h,children:"Clear"}),a.jsxs(r.Stack,{direction:"horizontal",children:[a.jsx(r.TextField,{label:e==null?void 0:e.gteMinLabel,type:"number",min:e==null?void 0:e.gteMin,max:e==null?void 0:e.lteMax,value:o.gte.toString(),onChange:N}),a.jsx(r.TextField,{label:e==null?void 0:e.lteMaxLabel,type:"number",min:e==null?void 0:e.gteMin,max:e==null?void 0:e.lteMax,value:o.lte.toString(),onChange:C})]}),a.jsx(L.MUISlider,{value:q,onChange:S,min:e==null?void 0:e.gteMin,max:e==null?void 0:e.lteMax,valueLabelDisplay:"auto"})]})});exports.NumberRangeFilter=I;
|
package/dist/index31.js
CHANGED
|
@@ -3,7 +3,7 @@ import { useState as y, useCallback as I } from "react";
|
|
|
3
3
|
import { observer as k } from "mobx-react";
|
|
4
4
|
import E from "lodash/debounce";
|
|
5
5
|
import { Stack as c, Button as _, TextField as p } from "@veeqo/ui";
|
|
6
|
-
import { MUISlider as A } from "./
|
|
6
|
+
import { MUISlider as A } from "./index114.js";
|
|
7
7
|
import { NumberRangeFilter as h } from "./index69.js";
|
|
8
8
|
import { useBusinessLogic as B } from "./index8.js";
|
|
9
9
|
import { useStores as T } from "./index61.js";
|
package/dist/index34.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),s=require("mobx-react"),n=require("@veeqo/ui"),o=require("./index8.cjs"),u=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),s=require("mobx-react"),n=require("@veeqo/ui"),o=require("./index8.cjs"),u=require("./index104.cjs"),c=require("./index35.cjs"),a=s.observer(()=>{const{GROUP_MAP:t}=o.useBusinessLogic();return e.jsx(u.AdaptiveHeightContainer,{style:{minWidth:"360px"},children:e.jsx(n.Stack,{alignX:"stretch",children:Array.from(t).map(([r,i])=>e.jsx(c.FilterGroup,{data:i},r))})})});exports.FiltersList=a;
|
package/dist/index34.js
CHANGED
|
@@ -2,7 +2,7 @@ import { jsx as r } from "react/jsx-runtime";
|
|
|
2
2
|
import { observer as e } from "mobx-react";
|
|
3
3
|
import { Stack as m } from "@veeqo/ui";
|
|
4
4
|
import { useBusinessLogic as s } from "./index8.js";
|
|
5
|
-
import { AdaptiveHeightContainer as p } from "./
|
|
5
|
+
import { AdaptiveHeightContainer as p } from "./index104.js";
|
|
6
6
|
import { FilterGroup as n } from "./index35.js";
|
|
7
7
|
const u = e(() => {
|
|
8
8
|
const { GROUP_MAP: t } = s();
|
package/dist/index36.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),c=require("react"),l=require("@veeqo/ui"),U=require("mobx-react"),z=require("./index65.cjs"),G=require("./index62.cjs"),J=require("./index40.cjs"),K=require("./index43.cjs"),Q=require("./index56.cjs"),X=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),c=require("react"),l=require("@veeqo/ui"),U=require("mobx-react"),z=require("./index65.cjs"),G=require("./index62.cjs"),J=require("./index40.cjs"),K=require("./index43.cjs"),Q=require("./index56.cjs"),X=require("./index100.cjs"),Z=require("./index8.cjs"),$=require("./index61.cjs"),b=require("./index101.cjs"),ee=U.observer(({view:e})=>{const{VIEW_TYPE:x,IS_VIEWS_READONLY:r,SEARCH_FILTER_ID:d}=Z.useBusinessLogic(),{Filters:{activeViewId:w,initFiltersFromView:f,discardChanges:m,initFromUrl:V,filters:L,setFilter:T},Views:{draftViewsMap:y},Notifications:{notify:E}}=$.useStores(),{viewsMap:h,defaultCustomViewId:F,isLoading:N}=G.useViews(),{isLoading:j}=z.useCustomViews({type:x}),{viewCounts:M,isLoadingViewCounts:R}=X.useViewCounts(e.id),[s,P]=c.useState(null),k=o=>{const q=L.get(d);if(h.has(o)){const n=h.get(o);n&&(f(n),m(!0),V())}else{const n=y.get(o);n?(f(n),m(!0),V()):E({type:"error",text:"Failed to load view"})}q&&T(d,q)},u=(e==null?void 0:e.id)===w,t=e.originalView!==void 0,g=e.originalView===void 0,A=M,a=(e==null?void 0:e.label)||"",I=N||j,p=c.useRef(!1);!I&&!p.current&&u&&e.id===F&&s&&(p.current=!0,s&&w===e.id&&window.requestAnimationFrame(()=>{var o;(o=s.parentElement)==null||o.scrollBy({behavior:"smooth",left:s.offsetLeft})}));const C=c.useMemo(()=>t?"draft":e.editable?"saved":"fixed",[t,e.editable]),{actions:{create:{handleSaveDraft:_},menu:{toggleDropdown:D},delete:{closeDeleteConfirmation:B,handleDelete:O,handleDeleteDraftView:v}},state:{shouldShowDeleteConfirmation:H},actions:W,state:S}=Q.useDropdownManager(e),Y=c.useMemo(()=>{if(!r){if(g)return D;if(t)return v}},[v,t,g,D,r]);return i.jsxs(i.Fragment,{children:[i.jsx(l.ViewTab,{customTextColour:e.customTextColour,colourPalette:e.colourPalette,className:"act-react-listing-custom-view",active:u,id:e==null?void 0:e.id,name:a,type:r?void 0:C,count:R?i.jsx(l.Loader,{type:"ThreeDots",width:12,height:12,color:u?"#fff":l.theme.colors.neutral.ink.dark}):A,onClick:k,subAction:Y,ariaContext:"orders",ref:P,"aria-controls":"options-dropdown","aria-expanded":S.shouldShowDropdown,"aria-haspopup":"dialog"},e==null?void 0:e.id),i.jsx(b.Confirmation,{shouldShow:H,viewName:a,onCancel:B,onDelete:O}),i.jsx(J.PillNotifications,{tabType:C,isActive:u,initialViewName:a,shouldShowCreateViewNotification:t,handleSaveDraft:_}),!r&&i.jsx(K.ViewDropdowns,{referenceElement:s,tab:e,...W,...S})]})});exports.ViewTab=ee;
|
package/dist/index36.js
CHANGED
|
@@ -7,16 +7,16 @@ import { useViews as Z } from "./index62.js";
|
|
|
7
7
|
import { PillNotifications as b } from "./index40.js";
|
|
8
8
|
import { ViewDropdowns as ee } from "./index43.js";
|
|
9
9
|
import { useDropdownManager as oe } from "./index56.js";
|
|
10
|
-
import { useViewCounts as ie } from "./
|
|
10
|
+
import { useViewCounts as ie } from "./index100.js";
|
|
11
11
|
import { useBusinessLogic as te } from "./index8.js";
|
|
12
12
|
import { useStores as re } from "./index61.js";
|
|
13
|
-
import { Confirmation as se } from "./
|
|
13
|
+
import { Confirmation as se } from "./index101.js";
|
|
14
14
|
const ve = Q(({ view: e }) => {
|
|
15
15
|
const { VIEW_TYPE: L, IS_VIEWS_READONLY: n, SEARCH_FILTER_ID: c } = te(), {
|
|
16
16
|
Filters: { activeViewId: d, initFiltersFromView: f, discardChanges: m, initFromUrl: u, filters: T, setFilter: x },
|
|
17
17
|
Views: { draftViewsMap: E },
|
|
18
18
|
Notifications: { notify: F }
|
|
19
|
-
} = re(), { viewsMap: w, defaultCustomViewId: y, isLoading: N } = Z(), { isLoading: A } = X({ type: L }), { viewCounts: I, isLoadingViewCounts: R } = ie(), [i, _] = $(null), k = (o) => {
|
|
19
|
+
} = re(), { viewsMap: w, defaultCustomViewId: y, isLoading: N } = Z(), { isLoading: A } = X({ type: L }), { viewCounts: I, isLoadingViewCounts: R } = ie(e.id), [i, _] = $(null), k = (o) => {
|
|
20
20
|
const D = T.get(c);
|
|
21
21
|
if (w.has(o)) {
|
|
22
22
|
const r = w.get(o);
|
package/dist/index39.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./index99.cjs"),g=require("./index52.cjs"),j=require("./index51.cjs"),M=({tab:i,onMakeDefault:l,onEdit:n,onDuplicate:s,onDelete:o,shouldShowDropdown:a,handleCloseDropdown:c})=>{const{openModal:r}=g.useModal(),d=()=>{r(j.ModalId.ORDERS_TABLE_MANAGEMENT),c()},m=i.label!=="Picking In Progress"&&i.editable,u=i.default!==!1&&i.editable,p=i.editable,b=i.editable;return a?e.jsxs(t.MenuItems,{children:[u&&e.jsx(t.Item,{onClick:l,className:"act-react-listing-custom-view-make-default-menu-item",children:"Make default view"}),b&&e.jsx(t.Item,{onClick:n,className:"act-react-listing-custom-view-edit-menu-item",role:"option",children:"Edit"}),e.jsx(t.Item,{onClick:s,className:"act-react-listing-custom-view-duplicate-menu-item",role:"option",children:"Duplicate"}),m&&e.jsx(t.Item,{onClick:o,className:"act-react-listing-custom-view-delete-menu-item",role:"option",children:"Delete"}),p&&e.jsxs(e.Fragment,{children:[e.jsx(t.Divider,{}),e.jsx(t.Item,{onClick:d,role:"option",children:"Table management"})]})]}):null};exports.OptionsDropdown=M;
|
package/dist/index39.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as t, jsx as i, Fragment as f } from "react/jsx-runtime";
|
|
2
|
-
import { MenuItems as M, Item as l, Divider as h } from "./
|
|
2
|
+
import { MenuItems as M, Item as l, Divider as h } from "./index99.js";
|
|
3
3
|
import { useModal as k } from "./index52.js";
|
|
4
4
|
import { ModalId as T } from "./index51.js";
|
|
5
5
|
const N = ({
|
package/dist/index41.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),n=require("react"),m=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),n=require("react"),m=require("./index106.cjs"),g=require("./index65.cjs"),S=require("./index62.cjs"),b=require("./index4.cjs"),y=require("./index8.cjs"),V=require("./index61.cjs"),p=require("./index12.cjs"),q=()=>{const{VIEW_TYPE:u}=y.useBusinessLogic(),{sortedCustomViews:s,isLoading:a}=S.useViews(),{mutate:c}=g.useCustomViews({type:u}),[l,t]=n.useState(s);n.useEffect(()=>{t(s)},[s]);const{Notifications:{notify:w}}=V.useStores(),d=async o=>{t(o);const r=o.map(e=>e.id);try{await b.patchCurrentUser({user_setting_attributes:{custom_view_positions:{order:r}}}),await c(e=>({...e,settings:{...e.settings,custom_view_positions:{...e.settings.custom_view_positions,order:r}}}),{revalidate:!1})}catch{t(s),w({type:"error",text:"Failed to update order of views"})}};return a||!s.length?null:i.jsx(p.ErrorBoundary,{children:i.jsx(m.LegacySortableViews,{views:l,onChange:d,className:"act-sortable-views"})})};exports.SortableViews=q;
|
package/dist/index41.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { useState as f, useEffect as l } from "react";
|
|
3
|
-
import { LegacySortableViews as w } from "./
|
|
3
|
+
import { LegacySortableViews as w } from "./index106.js";
|
|
4
4
|
import { useCustomViews as d } from "./index65.js";
|
|
5
5
|
import { useViews as g } from "./index62.js";
|
|
6
6
|
import { patchCurrentUser as _ } from "./index4.js";
|
package/dist/index47.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),h=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),h=require("./index88.cjs"),e=require("@veeqo/ui"),o=require("./index89.cjs"),d=require("./index61.cjs"),m=({isLoading:a,refetch:n,trackMetricClick:s,tooltipText:l="Refresh data",buttonProps:i={size:"sm",variant:"default"}})=>{const{hasChanges:r,acknowledgeButtonClick:u}=h.usePollData(),{Notifications:{notify:c}}=d.useStores(),f=async()=>{try{await n(),await u(),s==null||s()}catch{c({type:"error",text:"Failed to refresh data"})}};return t.jsxs(e.Tooltip,{className:o.default.refreshTooltip,text:l,children:[t.jsx(e.Button,{className:o.default.refreshButton,onClick:f,loading:a,disabled:a,iconSlot:t.jsx(e.RefreshIcon,{color:e.theme.colors.neutral.ink.base}),"aria-label":r?"refresh table with changes":"refresh table","aria-live":"polite",...i}),t.jsx(e.Indicator,{className:o.default.refreshIndicator,color:"red",size:"xs",style:{opacity:r?1:0}})]})};exports.RefreshButton=m;
|
package/dist/index47.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as m, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { usePollData as c } from "./
|
|
2
|
+
import { usePollData as c } from "./index88.js";
|
|
3
3
|
import { Tooltip as d, Button as p, RefreshIcon as u, theme as y, Indicator as x } from "@veeqo/ui";
|
|
4
|
-
import t from "./
|
|
4
|
+
import t from "./index89.js";
|
|
5
5
|
import { useStores as b } from "./index61.js";
|
|
6
6
|
const j = ({
|
|
7
7
|
isLoading: s,
|
package/dist/index78.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("@internationalized/date"),f=require("./index70.cjs"),F=require("./index69.cjs"),R=require("lodash/get"),A=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("@internationalized/date"),f=require("./index70.cjs"),F=require("./index69.cjs"),R=require("lodash/get"),A=require("./index105.cjs"),_=require("./index9.cjs"),T=r=>r&&r.__esModule?r:{default:r},n=T(R),h=({view:r,canUpdateCustomViews:g})=>{var u,c;const{DATE_RANGE_FILTERS:a,NUMBER_RANGE_FILTERS:o,GROUP_MAP:p}=_.BusinessLogicManager.getBusinessLogic(),s=Array.from(p.values()).flatMap(e=>e.fields),l=r.filters.filter||{},{colourPalette:m,customTextColour:b}=A.getViewTheme((u=r.view_attributes)==null?void 0:u.type);return{id:r.id,label:r.title,viewFilters:l,filterMaps:{filters:new Map(s.filter(e=>!a.includes(e.id)&&!o.includes(e.id)&&e.filterType!=="checkbox").map(e=>{const t=n.default(l,e.id);return[e.id,t!==void 0&&!Array.isArray(t)&&typeof t!="object"?String(t):""]}).filter(([,e])=>e!=="")),arrayFilters:new Map(s.filter(e=>e.filterType==="checkbox").map(e=>{const t=n.default(l,e.id);return[e.id,Array.isArray(t)?t:[]]}).filter(([,e])=>e.length>0)),rangeFilters:new Map(s.filter(e=>a.includes(e.id)).map(e=>{const t=n.default(l,e.id);if(!t)return null;let i;if(typeof t=="string")i=new f.RangeFilter(t);else if(typeof t=="object"&&t.gte&&t.lte){i=new f.RangeFilter("CUSTOM");const y=d.parseDate(t.gte),M=d.parseDate(t.lte);i.setDates(y,M)}else return null;return[e.id,i]}).filter(e=>e!==null)),numberRangeFilters:new Map(s.filter(e=>o.includes(e.id)).map(e=>{const t=n.default(l,e.id);if(!t||typeof t!="object")return null;const i=new F.NumberRangeFilter({filterId:e.id});return t.lte!==void 0&&i.setLte(Number(t.lte)),t.gte!==void 0&&i.setGte(Number(t.gte)),[e.id,i]}).filter(e=>e!==null))},page:r.filters.page,editable:r.editable&&g,isShared:r.shared,columns:r.columns,sort:(c=r.filters)==null?void 0:c.sort,colourPalette:m,customTextColour:b}};exports.viewsAdapter=h;
|
package/dist/index78.js
CHANGED
|
@@ -2,35 +2,36 @@ import { parseDate as c } from "@internationalized/date";
|
|
|
2
2
|
import { RangeFilter as p } from "./index70.js";
|
|
3
3
|
import { NumberRangeFilter as M } from "./index69.js";
|
|
4
4
|
import n from "lodash/get";
|
|
5
|
-
import { getViewTheme as F } from "./
|
|
5
|
+
import { getViewTheme as F } from "./index105.js";
|
|
6
6
|
import { BusinessLogicManager as R } from "./index9.js";
|
|
7
7
|
const S = ({
|
|
8
8
|
view: r,
|
|
9
9
|
canUpdateCustomViews: m
|
|
10
10
|
}) => {
|
|
11
11
|
var u, f;
|
|
12
|
-
const { DATE_RANGE_FILTERS: o, NUMBER_RANGE_FILTERS: a, GROUP_MAP: d } = R.getBusinessLogic(),
|
|
12
|
+
const { DATE_RANGE_FILTERS: o, NUMBER_RANGE_FILTERS: a, GROUP_MAP: d } = R.getBusinessLogic(), s = Array.from(d.values()).flatMap((e) => e.fields), l = r.filters.filter || {}, { colourPalette: g, customTextColour: b } = F((u = r.view_attributes) == null ? void 0 : u.type);
|
|
13
13
|
return {
|
|
14
14
|
id: r.id,
|
|
15
15
|
label: r.title,
|
|
16
|
+
viewFilters: l,
|
|
16
17
|
filterMaps: {
|
|
17
18
|
filters: new Map(
|
|
18
|
-
|
|
19
|
+
s.filter(
|
|
19
20
|
(e) => !o.includes(e.id) && !a.includes(e.id) && e.filterType !== "checkbox"
|
|
20
21
|
).map((e) => {
|
|
21
|
-
const t = n(
|
|
22
|
+
const t = n(l, e.id);
|
|
22
23
|
return [e.id, t !== void 0 && !Array.isArray(t) && typeof t != "object" ? String(t) : ""];
|
|
23
24
|
}).filter(([, e]) => e !== "")
|
|
24
25
|
),
|
|
25
26
|
arrayFilters: new Map(
|
|
26
|
-
|
|
27
|
-
const t = n(
|
|
27
|
+
s.filter((e) => e.filterType === "checkbox").map((e) => {
|
|
28
|
+
const t = n(l, e.id);
|
|
28
29
|
return [e.id, Array.isArray(t) ? t : []];
|
|
29
30
|
}).filter(([, e]) => e.length > 0)
|
|
30
31
|
),
|
|
31
32
|
rangeFilters: new Map(
|
|
32
|
-
|
|
33
|
-
const t = n(
|
|
33
|
+
s.filter((e) => o.includes(e.id)).map((e) => {
|
|
34
|
+
const t = n(l, e.id);
|
|
34
35
|
if (!t) return null;
|
|
35
36
|
let i;
|
|
36
37
|
if (typeof t == "string")
|
|
@@ -45,8 +46,8 @@ const S = ({
|
|
|
45
46
|
}).filter((e) => e !== null)
|
|
46
47
|
),
|
|
47
48
|
numberRangeFilters: new Map(
|
|
48
|
-
|
|
49
|
-
const t = n(
|
|
49
|
+
s.filter((e) => a.includes(e.id)).map((e) => {
|
|
50
|
+
const t = n(l, e.id);
|
|
50
51
|
if (!t || typeof t != "object") return null;
|
|
51
52
|
const i = new M({ filterId: e.id });
|
|
52
53
|
return t.lte !== void 0 && i.setLte(Number(t.lte)), t.gte !== void 0 && i.setGte(Number(t.gte)), [e.id, i];
|
package/dist/index79.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("@veeqo/ui"),e="all",r=()=>({id:e,label:"All",filterMaps:{filters:new Map,arrayFilters:new Map,rangeFilters:new Map,numberRangeFilters:new Map},page:{size:10},editable:!1,isShared:!1,columns:{columnIds:[],columnWidths:{}},colourPalette:l.theme.colors.secondary.blue});exports.ALL_VIEW_ID=e;exports.createAllView=r;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("@veeqo/ui"),e="all",r=()=>({id:e,label:"All",viewFilters:{},filterMaps:{filters:new Map,arrayFilters:new Map,rangeFilters:new Map,numberRangeFilters:new Map},page:{size:10},editable:!1,isShared:!1,columns:{columnIds:[],columnWidths:{}},colourPalette:l.theme.colors.secondary.blue});exports.ALL_VIEW_ID=e;exports.createAllView=r;
|
package/dist/index79.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { theme as e } from "@veeqo/ui";
|
|
2
|
-
const l = "all",
|
|
2
|
+
const l = "all", a = () => ({
|
|
3
3
|
id: l,
|
|
4
4
|
label: "All",
|
|
5
|
+
viewFilters: {},
|
|
5
6
|
filterMaps: {
|
|
6
7
|
filters: /* @__PURE__ */ new Map(),
|
|
7
8
|
arrayFilters: /* @__PURE__ */ new Map(),
|
|
@@ -21,5 +22,5 @@ const l = "all", r = () => ({
|
|
|
21
22
|
});
|
|
22
23
|
export {
|
|
23
24
|
l as ALL_VIEW_ID,
|
|
24
|
-
|
|
25
|
+
a as createAllView
|
|
25
26
|
};
|
package/dist/index80.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index103.cjs"),w=require("./index79.cjs"),V=require("./index78.cjs"),d=({data:n,canUpdateCustomViews:u})=>{const l={fixedViews:[...r.INITIAL_VIEWS_STATE.fixedViews],customViews:[...r.INITIAL_VIEWS_STATE.customViews],viewsMap:new Map(r.INITIAL_VIEWS_STATE.viewsMap)};if(!n)return l;let o=!1;const i=n.reduce((e,s)=>{const t=V.viewsAdapter({view:s,canUpdateCustomViews:u});return e.viewsMap.set(s.id,t),s.editable?e.customViews.push(t):e.fixedViews.push(t),s.title==="All"&&(o=!0),e},l);return o&&(i.viewsMap.delete(w.ALL_VIEW_ID),i.fixedViews.shift()),i};exports.organiseViews=d;
|
package/dist/index80.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { INITIAL_VIEWS_STATE as r } from "./
|
|
1
|
+
import { INITIAL_VIEWS_STATE as r } from "./index103.js";
|
|
2
2
|
import { ALL_VIEW_ID as p } from "./index79.js";
|
|
3
3
|
import { viewsAdapter as u } from "./index78.js";
|
|
4
4
|
const m = ({ data: o, canUpdateCustomViews: w }) => {
|
package/dist/index84.cjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index113.cjs"),s=e=>{if(!l.isError(e))return e;if(e.stack){const t=e.stack.split(`
|
|
2
2
|
`);if(t.length<=10)return e;const n=t==null?void 0:t[0],i=t==null?void 0:t.splice(9),r=[n,...i].join(`
|
|
3
3
|
`);e.stack=r}return e};exports.filterErrorStack=s;
|
package/dist/index84.js
CHANGED
package/dist/index85.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index113.cjs"),n=({customError:t,originalError:e,type:c})=>{!s.isError(e)||!s.isError(t)||(e.stack&&(e.stack=t.stack),e.name&&(e.name=`${c} (${e.name})`))};exports.injectIntoError=n;
|
package/dist/index85.js
CHANGED
package/dist/index86.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="_actionsHeaderContainer_fgqms_1",t={actionsHeaderContainer:e};exports.actionsHeaderContainer=e;exports.default=t;
|
package/dist/index86.js
CHANGED
|
@@ -1,43 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import { useStores as L } from "./index61.js";
|
|
5
|
-
import { useUrlParams as v } from "./index67.js";
|
|
6
|
-
import { fetcherV2 as V } from "./index55.js";
|
|
7
|
-
function T() {
|
|
8
|
-
const { TABLE_DATA_URL: h } = S(), {
|
|
9
|
-
Filters: {
|
|
10
|
-
pageSize: n,
|
|
11
|
-
activeViewId: s
|
|
12
|
-
}
|
|
13
|
-
} = L(), { queryParams: m } = v();
|
|
14
|
-
async function r() {
|
|
15
|
-
const e = `${h}?${m}`, g = await V(e);
|
|
16
|
-
return JSON.stringify(g);
|
|
17
|
-
}
|
|
18
|
-
const [c, a] = t(null), [l, u] = t(!1), [f, C] = t(s), [w, y] = t(n), i = 3e5, [D, o] = t(i);
|
|
19
|
-
return p(() => {
|
|
20
|
-
const e = () => {
|
|
21
|
-
document.hidden ? o(null) : o(i);
|
|
22
|
-
};
|
|
23
|
-
return document.addEventListener("visibilitychange", e), () => {
|
|
24
|
-
document.removeEventListener("visibilitychange", e);
|
|
25
|
-
};
|
|
26
|
-
}, []), P(
|
|
27
|
-
async () => {
|
|
28
|
-
const e = await r();
|
|
29
|
-
if (c === null || f !== s || w !== n) {
|
|
30
|
-
a(e), C(s), y(n);
|
|
31
|
-
return;
|
|
32
|
-
}
|
|
33
|
-
const d = e !== c;
|
|
34
|
-
d && (a(e), u(d));
|
|
35
|
-
},
|
|
36
|
-
l ? null : D
|
|
37
|
-
), { hasChanges: l, acknowledgeButtonClick: async () => {
|
|
38
|
-
u(!1), o(i), a(await r());
|
|
39
|
-
} };
|
|
40
|
-
}
|
|
1
|
+
const e = "_actionsHeaderContainer_fgqms_1", a = {
|
|
2
|
+
actionsHeaderContainer: e
|
|
3
|
+
};
|
|
41
4
|
export {
|
|
42
|
-
|
|
5
|
+
e as actionsHeaderContainer,
|
|
6
|
+
a as default
|
|
43
7
|
};
|
package/dist/index87.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=t=>t.trim().length>=3||t.trim().length===0;exports.isTextFilterValid=e;
|
package/dist/index87.js
CHANGED
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
const
|
|
2
|
-
refreshTooltip: e,
|
|
3
|
-
refreshButton: r,
|
|
4
|
-
refreshIndicator: t
|
|
5
|
-
};
|
|
1
|
+
const i = (t) => t.trim().length >= 3 || t.trim().length === 0;
|
|
6
2
|
export {
|
|
7
|
-
|
|
8
|
-
r as refreshButton,
|
|
9
|
-
t as refreshIndicator,
|
|
10
|
-
e as refreshTooltip
|
|
3
|
+
i as isTextFilterValid
|
|
11
4
|
};
|
package/dist/index88.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=t
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react"),w=require("react-use"),L=require("./index8.cjs"),m=require("./index61.cjs"),v=require("./index67.cjs"),q=require("./index55.cjs");function V(){const{TABLE_DATA_URL:h}=L.useBusinessLogic(),{Filters:{pageSize:s,activeViewId:n}}=m.useStores(),{queryParams:S}=v.useUrlParams();async function c(){const e=`${h}?${S}`,g=await q.fetcherV2(e);return JSON.stringify(g)}const[u,a]=t.useState(null),[o,l]=t.useState(!1),[f,C]=t.useState(n),[y,P]=t.useState(s),i=3e5,[D,r]=t.useState(i);return t.useEffect(()=>{const e=()=>{document.hidden?r(null):r(i)};return document.addEventListener("visibilitychange",e),()=>{document.removeEventListener("visibilitychange",e)}},[]),w.useInterval(async()=>{const e=await c();if(u===null||f!==n||y!==s){a(e),C(n),P(s);return}const d=e!==u;d&&(a(e),l(d))},o?null:D),{hasChanges:o,acknowledgeButtonClick:async()=>{l(!1),r(i),a(await c())}}}exports.usePollData=V;
|
package/dist/index88.js
CHANGED
|
@@ -1,4 +1,43 @@
|
|
|
1
|
-
|
|
1
|
+
import { useState as t, useEffect as p } from "react";
|
|
2
|
+
import { useInterval as P } from "react-use";
|
|
3
|
+
import { useBusinessLogic as S } from "./index8.js";
|
|
4
|
+
import { useStores as L } from "./index61.js";
|
|
5
|
+
import { useUrlParams as v } from "./index67.js";
|
|
6
|
+
import { fetcherV2 as V } from "./index55.js";
|
|
7
|
+
function T() {
|
|
8
|
+
const { TABLE_DATA_URL: h } = S(), {
|
|
9
|
+
Filters: {
|
|
10
|
+
pageSize: n,
|
|
11
|
+
activeViewId: s
|
|
12
|
+
}
|
|
13
|
+
} = L(), { queryParams: m } = v();
|
|
14
|
+
async function r() {
|
|
15
|
+
const e = `${h}?${m}`, g = await V(e);
|
|
16
|
+
return JSON.stringify(g);
|
|
17
|
+
}
|
|
18
|
+
const [c, a] = t(null), [l, u] = t(!1), [f, C] = t(s), [w, y] = t(n), i = 3e5, [D, o] = t(i);
|
|
19
|
+
return p(() => {
|
|
20
|
+
const e = () => {
|
|
21
|
+
document.hidden ? o(null) : o(i);
|
|
22
|
+
};
|
|
23
|
+
return document.addEventListener("visibilitychange", e), () => {
|
|
24
|
+
document.removeEventListener("visibilitychange", e);
|
|
25
|
+
};
|
|
26
|
+
}, []), P(
|
|
27
|
+
async () => {
|
|
28
|
+
const e = await r();
|
|
29
|
+
if (c === null || f !== s || w !== n) {
|
|
30
|
+
a(e), C(s), y(n);
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
const d = e !== c;
|
|
34
|
+
d && (a(e), u(d));
|
|
35
|
+
},
|
|
36
|
+
l ? null : D
|
|
37
|
+
), { hasChanges: l, acknowledgeButtonClick: async () => {
|
|
38
|
+
u(!1), o(i), a(await r());
|
|
39
|
+
} };
|
|
40
|
+
}
|
|
2
41
|
export {
|
|
3
|
-
|
|
42
|
+
T as usePollData
|
|
4
43
|
};
|
package/dist/index89.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="_refreshTooltip_v0eu8_1",r="_refreshButton_v0eu8_5",t="_refreshIndicator_v0eu8_9",o={refreshTooltip:e,refreshButton:r,refreshIndicator:t};exports.default=o;exports.refreshButton=r;exports.refreshIndicator=t;exports.refreshTooltip=e;
|
package/dist/index89.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
const e = "
|
|
2
|
-
|
|
1
|
+
const e = "_refreshTooltip_v0eu8_1", r = "_refreshButton_v0eu8_5", t = "_refreshIndicator_v0eu8_9", o = {
|
|
2
|
+
refreshTooltip: e,
|
|
3
|
+
refreshButton: r,
|
|
4
|
+
refreshIndicator: t
|
|
3
5
|
};
|
|
4
6
|
export {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
+
o as default,
|
|
8
|
+
r as refreshButton,
|
|
9
|
+
t as refreshIndicator,
|
|
10
|
+
e as refreshTooltip
|
|
7
11
|
};
|
package/dist/index90.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("@veeqo/ui"),s=require("react"),w=require("@veeqo/components"),S=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("@veeqo/ui"),s=require("react"),w=require("@veeqo/components"),S=require("./index92.cjs"),i=require("./index93.cjs"),T=require("./index94.cjs"),V=require("./index95.cjs"),n=require("./index96.cjs"),D=require("./index91.cjs"),H=require("./index97.cjs"),j=require("./index98.cjs"),{Glyph:O}=w.VeeqoCommon,$=({onClose:u,columnDefinitions:G,hiddenColumns:d,visibleColumns:m,pinnedLeftColumnIds:y,pinnedRightColumnIds:f})=>{const[c,p]=s.useState(""),a=s.useMemo(()=>new Map(G.map(r=>[r.id,r])),[]),[o,g]=s.useState(()=>({[n.ColumnGroupIds.Hidden]:d,[n.ColumnGroupIds.Visible]:m})),I=s.useMemo(()=>{const r=o[n.ColumnGroupIds.Visible].map(t=>a.get(`${t}`));return j.filterColumnsBySearch(r,c)},[o,a,c]),v=s.useMemo(()=>{const r=o[n.ColumnGroupIds.Hidden].map(t=>a.get(`${t}`));return j.filterColumnsBySearch(r,c)},[o,a,c]),{isSavingColumns:h,saveColumns:M}=H.usePersistColumns({pinnedLeftColumnIds:y,pinnedRightColumnIds:f}),q=()=>{p(""),g({[n.ColumnGroupIds.Hidden]:d,[n.ColumnGroupIds.Visible]:m})},x=s.useCallback(r=>{if(p(r),!r){const t=new Set([...d,...m]);g(b=>({[n.ColumnGroupIds.Hidden]:b[n.ColumnGroupIds.Hidden].filter(C=>t.has(`${C}`)),[n.ColumnGroupIds.Visible]:b[n.ColumnGroupIds.Visible].filter(C=>t.has(`${C}`))}))}},[d,m]),k=s.useCallback(r=>{const t=a.get(`${r}`);return t?e.jsx(V.ColumnItem,{column:t,isDragOverlay:!0}):null},[a]);return e.jsx(l.Modal,{variant:"lg",style:{overflowY:"hidden"},shouldShow:!0,onClose:()=>u==null?void 0:u(),headerSlot:e.jsxs(i.HeaderContainer,{children:[e.jsxs(l.Stack,{direction:"horizontal",alignX:"between",alignY:"center",children:[e.jsxs(l.Stack,{direction:"horizontal",alignX:"start",alignY:"center",spacing:"sm",children:[e.jsx(D.TableManagementGlyph,{height:32,width:32}),e.jsx(l.Text,{variant:"headingLarge",as:"h1",children:"Table management"})]}),e.jsx(l.Button,{"aria-label":"Close modal",onClick:u,variant:"flat",iconSlot:e.jsx(O,{name:"close"})})]}),e.jsxs(l.Text,{variant:"subheadingMedium",children:["Show, hide, or change the order of the columns in the view, so you always see the data that's most important to you. Learn more with our"," ",e.jsx(l.Anchor,{href:"#",target:"_blank",children:"help guide (TODO)"}),"."]}),e.jsx(l.Text,{variant:"headingSmall",children:"Column management"}),e.jsx(i.ColumnSearch,{name:"column-search-query",placeholder:"Search",value:c,onChange:x,onClearClick:()=>x(""),fill:"100%"})]}),leftActions:[{label:"Reset",onClick:q,variant:"default",disabled:h}],rightActions:[{label:"Cancel",onClick:u,variant:"default",disabled:h},{label:"Save",onClick:()=>M({visibleColumns:o[n.ColumnGroupIds.Visible]}),variant:"primary",disabled:h,loading:h}],children:e.jsx(l.Stack,{spacing:"md",alignX:"stretch",children:e.jsx(l.Stack,{spacing:4,alignX:"stretch",children:e.jsx(T.DndContainer,{items:o,setItems:g,renderDragOverlay:k,children:e.jsx(i.Container,{children:e.jsxs(i.ColumnGroupsGrid,{columns:2,spacing:"xl",children:[e.jsx(S.ColumnGroup,{id:n.ColumnGroupIds.Visible,title:"Shown columns:",columns:I}),e.jsx(i.VerticalSeparator,{children:e.jsx(i.VerticalText,{children:"Drag & Drop columns"})}),e.jsx(S.ColumnGroup,{id:n.ColumnGroupIds.Hidden,title:"Hidden columns:",columns:v})]})})})})})})};exports.TableManagementModal=$;
|
package/dist/index90.js
CHANGED
|
@@ -2,14 +2,14 @@ import { jsx as e, jsxs as c } from "react/jsx-runtime";
|
|
|
2
2
|
import { Modal as O, Stack as h, Text as p, Button as X, Anchor as A } from "@veeqo/ui";
|
|
3
3
|
import { useState as v, useMemo as f, useCallback as y } from "react";
|
|
4
4
|
import { VeeqoCommon as I } from "@veeqo/components";
|
|
5
|
-
import { ColumnGroup as w } from "./
|
|
6
|
-
import { Container as Y, ColumnGroupsGrid as j, VerticalSeparator as z, VerticalText as B, HeaderContainer as L, ColumnSearch as Q } from "./
|
|
7
|
-
import { DndContainer as R } from "./
|
|
8
|
-
import { ColumnItem as q } from "./
|
|
9
|
-
import { ColumnGroupIds as n } from "./
|
|
5
|
+
import { ColumnGroup as w } from "./index92.js";
|
|
6
|
+
import { Container as Y, ColumnGroupsGrid as j, VerticalSeparator as z, VerticalText as B, HeaderContainer as L, ColumnSearch as Q } from "./index93.js";
|
|
7
|
+
import { DndContainer as R } from "./index94.js";
|
|
8
|
+
import { ColumnItem as q } from "./index95.js";
|
|
9
|
+
import { ColumnGroupIds as n } from "./index96.js";
|
|
10
10
|
import { TableManagementGlyph as P } from "./index91.js";
|
|
11
|
-
import { usePersistColumns as _ } from "./
|
|
12
|
-
import { filterColumnsBySearch as V } from "./
|
|
11
|
+
import { usePersistColumns as _ } from "./index97.js";
|
|
12
|
+
import { filterColumnsBySearch as V } from "./index98.js";
|
|
13
13
|
const { Glyph: E } = I, te = ({
|
|
14
14
|
onClose: l,
|
|
15
15
|
columnDefinitions: k,
|
package/dist/index92.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),o=require("@veeqo/ui"),s=require("@dnd-kit/sortable"),a=require("./index109.cjs"),l=require("./index110.cjs"),c=require("./index95.cjs"),u=require("./index96.cjs"),d=require("./index93.cjs"),m=({id:r,title:n,columns:i})=>e.jsxs(o.Stack,{spacing:"sm",alignX:"stretch",children:[e.jsx(d.StickyText,{variant:"bodyBold",children:n}),e.jsx(s.SortableContext,{id:r,items:i,strategy:s.verticalListSortingStrategy,children:e.jsx(l.DroppableArea,{id:r,spacing:"sm",alignX:"stretch",children:i.map(t=>e.jsx(a.SortableItem,{id:t.id,children:e.jsx(c.ColumnItem,{column:t,isHidden:r===u.ColumnGroupIds.Hidden})},t.id))})})]});exports.ColumnGroup=m;
|
package/dist/index92.js
CHANGED
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
};
|
|
1
|
+
import { jsxs as m, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { Stack as n } from "@veeqo/ui";
|
|
3
|
+
import { SortableContext as p, verticalListSortingStrategy as a } from "@dnd-kit/sortable";
|
|
4
|
+
import { SortableItem as s } from "./index109.js";
|
|
5
|
+
import { DroppableArea as d } from "./index110.js";
|
|
6
|
+
import { ColumnItem as l } from "./index95.js";
|
|
7
|
+
import { ColumnGroupIds as c } from "./index96.js";
|
|
8
|
+
import { StickyText as f } from "./index93.js";
|
|
9
|
+
const I = ({ id: t, title: e, columns: o }) => /* @__PURE__ */ m(n, { spacing: "sm", alignX: "stretch", children: [
|
|
10
|
+
/* @__PURE__ */ r(f, { variant: "bodyBold", children: e }),
|
|
11
|
+
/* @__PURE__ */ r(p, { id: t, items: o, strategy: a, children: /* @__PURE__ */ r(d, { id: t, spacing: "sm", alignX: "stretch", children: o.map((i) => /* @__PURE__ */ r(s, { id: i.id, children: /* @__PURE__ */ r(l, { column: i, isHidden: t === c.Hidden }) }, i.id)) }) })
|
|
12
|
+
] });
|
|
7
13
|
export {
|
|
8
|
-
|
|
14
|
+
I as ColumnGroup
|
|
9
15
|
};
|