@gobolt/genesis 0.4.5 → 0.4.7
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/components/Table/__mocks__/table-mocks.d.ts +12 -0
- package/dist/index.cjs +213 -32
- package/dist/index.js +213 -32
- package/package.json +1 -1
|
@@ -9,6 +9,18 @@ export interface AppointmentWithSimpleAddress {
|
|
|
9
9
|
address: string;
|
|
10
10
|
};
|
|
11
11
|
job_subtype: "delivery" | "pickup";
|
|
12
|
+
progress?: {
|
|
13
|
+
firstBarData: {
|
|
14
|
+
text: string;
|
|
15
|
+
status: string;
|
|
16
|
+
value: number;
|
|
17
|
+
};
|
|
18
|
+
secondBarData?: {
|
|
19
|
+
text: string;
|
|
20
|
+
status: string;
|
|
21
|
+
value: number;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
12
24
|
}
|
|
13
25
|
export interface MockDataSource {
|
|
14
26
|
appointments: AppointmentWithSimpleAddress[];
|
package/dist/index.cjs
CHANGED
|
@@ -80792,15 +80792,12 @@ const getTextComponent = (firstBarData, secondBarData, stateColor, theme, isText
|
|
|
80792
80792
|
);
|
|
80793
80793
|
};
|
|
80794
80794
|
const getCombinedPercent = (firstBarData, secondBarData) => {
|
|
80795
|
-
if (secondBarData?.value
|
|
80796
|
-
|
|
80797
|
-
}
|
|
80798
|
-
if (firstBarData?.value && secondBarData?.value) {
|
|
80799
|
-
const total = firstBarData?.value + secondBarData?.value;
|
|
80795
|
+
if (firstBarData?.value !== void 0 && secondBarData?.value !== void 0) {
|
|
80796
|
+
const total = firstBarData.value + secondBarData.value;
|
|
80800
80797
|
const dividedBy = total / 2;
|
|
80801
|
-
return dividedBy;
|
|
80798
|
+
return Math.round(dividedBy * 10) / 10;
|
|
80802
80799
|
}
|
|
80803
|
-
return 0;
|
|
80800
|
+
return firstBarData?.value || 0;
|
|
80804
80801
|
};
|
|
80805
80802
|
const Progress = ({
|
|
80806
80803
|
firstBarData,
|
|
@@ -80819,6 +80816,7 @@ const Progress = ({
|
|
|
80819
80816
|
strokeColor: theme?.colors?.inputs?.progress?.[secondBarData.status]
|
|
80820
80817
|
} : null;
|
|
80821
80818
|
const stateColor = strokeColor;
|
|
80819
|
+
const percentDisplayWidth = 110;
|
|
80822
80820
|
const gap = 8;
|
|
80823
80821
|
if (isSingleBarOverallSuccess && secondBarData !== null) {
|
|
80824
80822
|
const overallPercent = secondBarData.value;
|
|
@@ -80834,30 +80832,79 @@ const Progress = ({
|
|
|
80834
80832
|
showInfo: false
|
|
80835
80833
|
}
|
|
80836
80834
|
),
|
|
80837
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
80838
|
-
|
|
80839
|
-
|
|
80840
|
-
|
|
80835
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
80836
|
+
"div",
|
|
80837
|
+
{
|
|
80838
|
+
style: {
|
|
80839
|
+
display: "flex",
|
|
80840
|
+
alignItems: "center",
|
|
80841
|
+
width: percentDisplayWidth
|
|
80842
|
+
},
|
|
80843
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80844
|
+
overallPercent,
|
|
80845
|
+
"%"
|
|
80846
|
+
] })
|
|
80847
|
+
}
|
|
80848
|
+
)
|
|
80841
80849
|
] });
|
|
80842
80850
|
}
|
|
80843
80851
|
if (isProgressCombined) {
|
|
80844
80852
|
const combinedPercent = getCombinedPercent(firstBarData, secondBarData);
|
|
80845
80853
|
const textColor = Number(combinedPercent) === 100 ? "green" : "black";
|
|
80854
|
+
const adjustedFirstBar = secondBarData?.value === 100 ? 100 : firstBarData?.value || 0;
|
|
80855
|
+
const firstBarStrokeColor = theme?.colors?.inputs?.progress?.[firstBarData?.status || "info"];
|
|
80856
|
+
const secondBarStrokeColor = secondBarData?.value && secondBarData.value > 0 ? theme?.colors?.inputs?.progress?.[secondBarData.status] : null;
|
|
80857
|
+
secondBarData?.value && secondBarData.value > 0 ? {
|
|
80858
|
+
percent: secondBarData.value
|
|
80859
|
+
} : null;
|
|
80846
80860
|
return /* @__PURE__ */ jsxRuntime.jsxs(Tile, { style: { width, height, alignItems: "center", gap }, isHorizontal: true, children: [
|
|
80861
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { position: "relative", width: "100%" }, children: [
|
|
80862
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
80863
|
+
Progress$1,
|
|
80864
|
+
{
|
|
80865
|
+
"data-testid": "progress",
|
|
80866
|
+
percent: adjustedFirstBar,
|
|
80867
|
+
strokeColor: firstBarStrokeColor,
|
|
80868
|
+
showInfo: false
|
|
80869
|
+
}
|
|
80870
|
+
),
|
|
80871
|
+
secondBarData?.value && secondBarData.value > 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
80872
|
+
"div",
|
|
80873
|
+
{
|
|
80874
|
+
style: {
|
|
80875
|
+
position: "absolute",
|
|
80876
|
+
top: 0,
|
|
80877
|
+
left: 0,
|
|
80878
|
+
width: "100%",
|
|
80879
|
+
height: "100%",
|
|
80880
|
+
pointerEvents: "none"
|
|
80881
|
+
},
|
|
80882
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
80883
|
+
Progress$1,
|
|
80884
|
+
{
|
|
80885
|
+
percent: secondBarData.value,
|
|
80886
|
+
strokeColor: secondBarStrokeColor,
|
|
80887
|
+
showInfo: false,
|
|
80888
|
+
style: { background: "transparent" }
|
|
80889
|
+
}
|
|
80890
|
+
)
|
|
80891
|
+
}
|
|
80892
|
+
) : null
|
|
80893
|
+
] }),
|
|
80847
80894
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
80848
|
-
|
|
80895
|
+
"div",
|
|
80849
80896
|
{
|
|
80850
|
-
|
|
80851
|
-
|
|
80852
|
-
|
|
80853
|
-
|
|
80854
|
-
|
|
80897
|
+
style: {
|
|
80898
|
+
display: "flex",
|
|
80899
|
+
alignItems: "center",
|
|
80900
|
+
width: percentDisplayWidth
|
|
80901
|
+
},
|
|
80902
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80903
|
+
combinedPercent,
|
|
80904
|
+
"%"
|
|
80905
|
+
] })
|
|
80855
80906
|
}
|
|
80856
|
-
)
|
|
80857
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", alignItems: "center", width: 80 }, children: /* @__PURE__ */ jsxRuntime.jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80858
|
-
combinedPercent,
|
|
80859
|
-
"%"
|
|
80860
|
-
] }) })
|
|
80907
|
+
)
|
|
80861
80908
|
] });
|
|
80862
80909
|
}
|
|
80863
80910
|
if (isTextBeforeBar) {
|
|
@@ -84567,6 +84614,20 @@ const mockColumns = [
|
|
|
84567
84614
|
state: colorStateMap[jobSubtype]
|
|
84568
84615
|
});
|
|
84569
84616
|
}
|
|
84617
|
+
},
|
|
84618
|
+
{
|
|
84619
|
+
title: "Progress",
|
|
84620
|
+
dataIndex: "progress",
|
|
84621
|
+
render: (progress) => {
|
|
84622
|
+
if (!progress) return null;
|
|
84623
|
+
return React.createElement(Progress, {
|
|
84624
|
+
firstBarData: progress.firstBarData,
|
|
84625
|
+
secondBarData: progress.secondBarData,
|
|
84626
|
+
width: 150,
|
|
84627
|
+
height: 20,
|
|
84628
|
+
isProgressCombined: true
|
|
84629
|
+
});
|
|
84630
|
+
}
|
|
84570
84631
|
}
|
|
84571
84632
|
];
|
|
84572
84633
|
mockColumns.map((column2) => ({
|
|
@@ -84583,7 +84644,19 @@ const mockDataSource = {
|
|
|
84583
84644
|
nickname: "Home",
|
|
84584
84645
|
address: "123 Main St"
|
|
84585
84646
|
},
|
|
84586
|
-
job_subtype: "delivery"
|
|
84647
|
+
job_subtype: "delivery",
|
|
84648
|
+
progress: {
|
|
84649
|
+
firstBarData: {
|
|
84650
|
+
text: "Loading",
|
|
84651
|
+
status: "info",
|
|
84652
|
+
value: 100
|
|
84653
|
+
},
|
|
84654
|
+
secondBarData: {
|
|
84655
|
+
text: "Processing",
|
|
84656
|
+
status: "success",
|
|
84657
|
+
value: 25
|
|
84658
|
+
}
|
|
84659
|
+
}
|
|
84587
84660
|
},
|
|
84588
84661
|
{
|
|
84589
84662
|
id: "2",
|
|
@@ -84594,7 +84667,19 @@ const mockDataSource = {
|
|
|
84594
84667
|
nickname: "Work",
|
|
84595
84668
|
address: "456 Elm St"
|
|
84596
84669
|
},
|
|
84597
|
-
job_subtype: "pickup"
|
|
84670
|
+
job_subtype: "pickup",
|
|
84671
|
+
progress: {
|
|
84672
|
+
firstBarData: {
|
|
84673
|
+
text: "Preparing",
|
|
84674
|
+
status: "info",
|
|
84675
|
+
value: 100
|
|
84676
|
+
},
|
|
84677
|
+
secondBarData: {
|
|
84678
|
+
text: "Final Check",
|
|
84679
|
+
status: "success",
|
|
84680
|
+
value: 0
|
|
84681
|
+
}
|
|
84682
|
+
}
|
|
84598
84683
|
},
|
|
84599
84684
|
{
|
|
84600
84685
|
id: "3",
|
|
@@ -84605,7 +84690,19 @@ const mockDataSource = {
|
|
|
84605
84690
|
nickname: "Store",
|
|
84606
84691
|
address: "789 Oak St"
|
|
84607
84692
|
},
|
|
84608
|
-
job_subtype: "delivery"
|
|
84693
|
+
job_subtype: "delivery",
|
|
84694
|
+
progress: {
|
|
84695
|
+
firstBarData: {
|
|
84696
|
+
text: "Pending",
|
|
84697
|
+
status: "info",
|
|
84698
|
+
value: 0
|
|
84699
|
+
},
|
|
84700
|
+
secondBarData: {
|
|
84701
|
+
text: "Awaiting",
|
|
84702
|
+
status: "success",
|
|
84703
|
+
value: 0
|
|
84704
|
+
}
|
|
84705
|
+
}
|
|
84609
84706
|
},
|
|
84610
84707
|
{
|
|
84611
84708
|
id: "4",
|
|
@@ -84616,7 +84713,19 @@ const mockDataSource = {
|
|
|
84616
84713
|
nickname: "Office",
|
|
84617
84714
|
address: "321 Pine St"
|
|
84618
84715
|
},
|
|
84619
|
-
job_subtype: "pickup"
|
|
84716
|
+
job_subtype: "pickup",
|
|
84717
|
+
progress: {
|
|
84718
|
+
firstBarData: {
|
|
84719
|
+
text: "In Progress",
|
|
84720
|
+
status: "info",
|
|
84721
|
+
value: 100
|
|
84722
|
+
},
|
|
84723
|
+
secondBarData: {
|
|
84724
|
+
text: "Validation",
|
|
84725
|
+
status: "success",
|
|
84726
|
+
value: 30
|
|
84727
|
+
}
|
|
84728
|
+
}
|
|
84620
84729
|
},
|
|
84621
84730
|
{
|
|
84622
84731
|
id: "5",
|
|
@@ -84627,7 +84736,19 @@ const mockDataSource = {
|
|
|
84627
84736
|
nickname: "Library",
|
|
84628
84737
|
address: "555 Book Lane"
|
|
84629
84738
|
},
|
|
84630
|
-
job_subtype: "delivery"
|
|
84739
|
+
job_subtype: "delivery",
|
|
84740
|
+
progress: {
|
|
84741
|
+
firstBarData: {
|
|
84742
|
+
text: "Completed",
|
|
84743
|
+
status: "info",
|
|
84744
|
+
value: 100
|
|
84745
|
+
},
|
|
84746
|
+
secondBarData: {
|
|
84747
|
+
text: "Verified",
|
|
84748
|
+
status: "success",
|
|
84749
|
+
value: 100
|
|
84750
|
+
}
|
|
84751
|
+
}
|
|
84631
84752
|
},
|
|
84632
84753
|
{
|
|
84633
84754
|
id: "6",
|
|
@@ -84638,7 +84759,19 @@ const mockDataSource = {
|
|
|
84638
84759
|
nickname: "Gym",
|
|
84639
84760
|
address: "777 Fitness Ave"
|
|
84640
84761
|
},
|
|
84641
|
-
job_subtype: "pickup"
|
|
84762
|
+
job_subtype: "pickup",
|
|
84763
|
+
progress: {
|
|
84764
|
+
firstBarData: {
|
|
84765
|
+
text: "Phase 1",
|
|
84766
|
+
status: "info",
|
|
84767
|
+
value: 75
|
|
84768
|
+
},
|
|
84769
|
+
secondBarData: {
|
|
84770
|
+
text: "Phase 2",
|
|
84771
|
+
status: "success",
|
|
84772
|
+
value: 50
|
|
84773
|
+
}
|
|
84774
|
+
}
|
|
84642
84775
|
},
|
|
84643
84776
|
{
|
|
84644
84777
|
id: "7",
|
|
@@ -84649,7 +84782,19 @@ const mockDataSource = {
|
|
|
84649
84782
|
nickname: "Mall",
|
|
84650
84783
|
address: "888 Shopping Center"
|
|
84651
84784
|
},
|
|
84652
|
-
job_subtype: "delivery"
|
|
84785
|
+
job_subtype: "delivery",
|
|
84786
|
+
progress: {
|
|
84787
|
+
firstBarData: {
|
|
84788
|
+
text: "Queued",
|
|
84789
|
+
status: "info",
|
|
84790
|
+
value: 0
|
|
84791
|
+
},
|
|
84792
|
+
secondBarData: {
|
|
84793
|
+
text: "Waiting",
|
|
84794
|
+
status: "success",
|
|
84795
|
+
value: 0
|
|
84796
|
+
}
|
|
84797
|
+
}
|
|
84653
84798
|
},
|
|
84654
84799
|
{
|
|
84655
84800
|
id: "8",
|
|
@@ -84660,7 +84805,19 @@ const mockDataSource = {
|
|
|
84660
84805
|
nickname: "School",
|
|
84661
84806
|
address: "999 Education Rd"
|
|
84662
84807
|
},
|
|
84663
|
-
job_subtype: "pickup"
|
|
84808
|
+
job_subtype: "pickup",
|
|
84809
|
+
progress: {
|
|
84810
|
+
firstBarData: {
|
|
84811
|
+
text: "Delivered",
|
|
84812
|
+
status: "info",
|
|
84813
|
+
value: 100
|
|
84814
|
+
},
|
|
84815
|
+
secondBarData: {
|
|
84816
|
+
text: "Confirmed",
|
|
84817
|
+
status: "success",
|
|
84818
|
+
value: 100
|
|
84819
|
+
}
|
|
84820
|
+
}
|
|
84664
84821
|
},
|
|
84665
84822
|
{
|
|
84666
84823
|
id: "9",
|
|
@@ -84671,7 +84828,19 @@ const mockDataSource = {
|
|
|
84671
84828
|
nickname: "Restaurant",
|
|
84672
84829
|
address: "111 Food Court"
|
|
84673
84830
|
},
|
|
84674
|
-
job_subtype: "delivery"
|
|
84831
|
+
job_subtype: "delivery",
|
|
84832
|
+
progress: {
|
|
84833
|
+
firstBarData: {
|
|
84834
|
+
text: "Preparing",
|
|
84835
|
+
status: "info",
|
|
84836
|
+
value: 100
|
|
84837
|
+
},
|
|
84838
|
+
secondBarData: {
|
|
84839
|
+
text: "Quality Check",
|
|
84840
|
+
status: "success",
|
|
84841
|
+
value: 15
|
|
84842
|
+
}
|
|
84843
|
+
}
|
|
84675
84844
|
},
|
|
84676
84845
|
{
|
|
84677
84846
|
id: "10",
|
|
@@ -84682,7 +84851,19 @@ const mockDataSource = {
|
|
|
84682
84851
|
nickname: "Park",
|
|
84683
84852
|
address: "222 Green Ave"
|
|
84684
84853
|
},
|
|
84685
|
-
job_subtype: "pickup"
|
|
84854
|
+
job_subtype: "pickup",
|
|
84855
|
+
progress: {
|
|
84856
|
+
firstBarData: {
|
|
84857
|
+
text: "Processing",
|
|
84858
|
+
status: "info",
|
|
84859
|
+
value: 80
|
|
84860
|
+
},
|
|
84861
|
+
secondBarData: {
|
|
84862
|
+
text: "Review",
|
|
84863
|
+
status: "success",
|
|
84864
|
+
value: 0
|
|
84865
|
+
}
|
|
84866
|
+
}
|
|
84686
84867
|
},
|
|
84687
84868
|
{
|
|
84688
84869
|
id: "11",
|
package/dist/index.js
CHANGED
|
@@ -80774,15 +80774,12 @@ const getTextComponent = (firstBarData, secondBarData, stateColor, theme, isText
|
|
|
80774
80774
|
);
|
|
80775
80775
|
};
|
|
80776
80776
|
const getCombinedPercent = (firstBarData, secondBarData) => {
|
|
80777
|
-
if (secondBarData?.value
|
|
80778
|
-
|
|
80779
|
-
}
|
|
80780
|
-
if (firstBarData?.value && secondBarData?.value) {
|
|
80781
|
-
const total = firstBarData?.value + secondBarData?.value;
|
|
80777
|
+
if (firstBarData?.value !== void 0 && secondBarData?.value !== void 0) {
|
|
80778
|
+
const total = firstBarData.value + secondBarData.value;
|
|
80782
80779
|
const dividedBy = total / 2;
|
|
80783
|
-
return dividedBy;
|
|
80780
|
+
return Math.round(dividedBy * 10) / 10;
|
|
80784
80781
|
}
|
|
80785
|
-
return 0;
|
|
80782
|
+
return firstBarData?.value || 0;
|
|
80786
80783
|
};
|
|
80787
80784
|
const Progress = ({
|
|
80788
80785
|
firstBarData,
|
|
@@ -80801,6 +80798,7 @@ const Progress = ({
|
|
|
80801
80798
|
strokeColor: theme?.colors?.inputs?.progress?.[secondBarData.status]
|
|
80802
80799
|
} : null;
|
|
80803
80800
|
const stateColor = strokeColor;
|
|
80801
|
+
const percentDisplayWidth = 110;
|
|
80804
80802
|
const gap = 8;
|
|
80805
80803
|
if (isSingleBarOverallSuccess && secondBarData !== null) {
|
|
80806
80804
|
const overallPercent = secondBarData.value;
|
|
@@ -80816,30 +80814,79 @@ const Progress = ({
|
|
|
80816
80814
|
showInfo: false
|
|
80817
80815
|
}
|
|
80818
80816
|
),
|
|
80819
|
-
/* @__PURE__ */ jsx(
|
|
80820
|
-
|
|
80821
|
-
|
|
80822
|
-
|
|
80817
|
+
/* @__PURE__ */ jsx(
|
|
80818
|
+
"div",
|
|
80819
|
+
{
|
|
80820
|
+
style: {
|
|
80821
|
+
display: "flex",
|
|
80822
|
+
alignItems: "center",
|
|
80823
|
+
width: percentDisplayWidth
|
|
80824
|
+
},
|
|
80825
|
+
children: /* @__PURE__ */ jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80826
|
+
overallPercent,
|
|
80827
|
+
"%"
|
|
80828
|
+
] })
|
|
80829
|
+
}
|
|
80830
|
+
)
|
|
80823
80831
|
] });
|
|
80824
80832
|
}
|
|
80825
80833
|
if (isProgressCombined) {
|
|
80826
80834
|
const combinedPercent = getCombinedPercent(firstBarData, secondBarData);
|
|
80827
80835
|
const textColor = Number(combinedPercent) === 100 ? "green" : "black";
|
|
80836
|
+
const adjustedFirstBar = secondBarData?.value === 100 ? 100 : firstBarData?.value || 0;
|
|
80837
|
+
const firstBarStrokeColor = theme?.colors?.inputs?.progress?.[firstBarData?.status || "info"];
|
|
80838
|
+
const secondBarStrokeColor = secondBarData?.value && secondBarData.value > 0 ? theme?.colors?.inputs?.progress?.[secondBarData.status] : null;
|
|
80839
|
+
secondBarData?.value && secondBarData.value > 0 ? {
|
|
80840
|
+
percent: secondBarData.value
|
|
80841
|
+
} : null;
|
|
80828
80842
|
return /* @__PURE__ */ jsxs(Tile, { style: { width, height, alignItems: "center", gap }, isHorizontal: true, children: [
|
|
80843
|
+
/* @__PURE__ */ jsxs("div", { style: { position: "relative", width: "100%" }, children: [
|
|
80844
|
+
/* @__PURE__ */ jsx(
|
|
80845
|
+
Progress$1,
|
|
80846
|
+
{
|
|
80847
|
+
"data-testid": "progress",
|
|
80848
|
+
percent: adjustedFirstBar,
|
|
80849
|
+
strokeColor: firstBarStrokeColor,
|
|
80850
|
+
showInfo: false
|
|
80851
|
+
}
|
|
80852
|
+
),
|
|
80853
|
+
secondBarData?.value && secondBarData.value > 0 ? /* @__PURE__ */ jsx(
|
|
80854
|
+
"div",
|
|
80855
|
+
{
|
|
80856
|
+
style: {
|
|
80857
|
+
position: "absolute",
|
|
80858
|
+
top: 0,
|
|
80859
|
+
left: 0,
|
|
80860
|
+
width: "100%",
|
|
80861
|
+
height: "100%",
|
|
80862
|
+
pointerEvents: "none"
|
|
80863
|
+
},
|
|
80864
|
+
children: /* @__PURE__ */ jsx(
|
|
80865
|
+
Progress$1,
|
|
80866
|
+
{
|
|
80867
|
+
percent: secondBarData.value,
|
|
80868
|
+
strokeColor: secondBarStrokeColor,
|
|
80869
|
+
showInfo: false,
|
|
80870
|
+
style: { background: "transparent" }
|
|
80871
|
+
}
|
|
80872
|
+
)
|
|
80873
|
+
}
|
|
80874
|
+
) : null
|
|
80875
|
+
] }),
|
|
80829
80876
|
/* @__PURE__ */ jsx(
|
|
80830
|
-
|
|
80877
|
+
"div",
|
|
80831
80878
|
{
|
|
80832
|
-
|
|
80833
|
-
|
|
80834
|
-
|
|
80835
|
-
|
|
80836
|
-
|
|
80879
|
+
style: {
|
|
80880
|
+
display: "flex",
|
|
80881
|
+
alignItems: "center",
|
|
80882
|
+
width: percentDisplayWidth
|
|
80883
|
+
},
|
|
80884
|
+
children: /* @__PURE__ */ jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80885
|
+
combinedPercent,
|
|
80886
|
+
"%"
|
|
80887
|
+
] })
|
|
80837
80888
|
}
|
|
80838
|
-
)
|
|
80839
|
-
/* @__PURE__ */ jsx("div", { style: { display: "flex", alignItems: "center", width: 80 }, children: /* @__PURE__ */ jsxs(Typography, { color: textColor, variant: "digits3", children: [
|
|
80840
|
-
combinedPercent,
|
|
80841
|
-
"%"
|
|
80842
|
-
] }) })
|
|
80889
|
+
)
|
|
80843
80890
|
] });
|
|
80844
80891
|
}
|
|
80845
80892
|
if (isTextBeforeBar) {
|
|
@@ -84549,6 +84596,20 @@ const mockColumns = [
|
|
|
84549
84596
|
state: colorStateMap[jobSubtype]
|
|
84550
84597
|
});
|
|
84551
84598
|
}
|
|
84599
|
+
},
|
|
84600
|
+
{
|
|
84601
|
+
title: "Progress",
|
|
84602
|
+
dataIndex: "progress",
|
|
84603
|
+
render: (progress) => {
|
|
84604
|
+
if (!progress) return null;
|
|
84605
|
+
return React__default.createElement(Progress, {
|
|
84606
|
+
firstBarData: progress.firstBarData,
|
|
84607
|
+
secondBarData: progress.secondBarData,
|
|
84608
|
+
width: 150,
|
|
84609
|
+
height: 20,
|
|
84610
|
+
isProgressCombined: true
|
|
84611
|
+
});
|
|
84612
|
+
}
|
|
84552
84613
|
}
|
|
84553
84614
|
];
|
|
84554
84615
|
mockColumns.map((column2) => ({
|
|
@@ -84565,7 +84626,19 @@ const mockDataSource = {
|
|
|
84565
84626
|
nickname: "Home",
|
|
84566
84627
|
address: "123 Main St"
|
|
84567
84628
|
},
|
|
84568
|
-
job_subtype: "delivery"
|
|
84629
|
+
job_subtype: "delivery",
|
|
84630
|
+
progress: {
|
|
84631
|
+
firstBarData: {
|
|
84632
|
+
text: "Loading",
|
|
84633
|
+
status: "info",
|
|
84634
|
+
value: 100
|
|
84635
|
+
},
|
|
84636
|
+
secondBarData: {
|
|
84637
|
+
text: "Processing",
|
|
84638
|
+
status: "success",
|
|
84639
|
+
value: 25
|
|
84640
|
+
}
|
|
84641
|
+
}
|
|
84569
84642
|
},
|
|
84570
84643
|
{
|
|
84571
84644
|
id: "2",
|
|
@@ -84576,7 +84649,19 @@ const mockDataSource = {
|
|
|
84576
84649
|
nickname: "Work",
|
|
84577
84650
|
address: "456 Elm St"
|
|
84578
84651
|
},
|
|
84579
|
-
job_subtype: "pickup"
|
|
84652
|
+
job_subtype: "pickup",
|
|
84653
|
+
progress: {
|
|
84654
|
+
firstBarData: {
|
|
84655
|
+
text: "Preparing",
|
|
84656
|
+
status: "info",
|
|
84657
|
+
value: 100
|
|
84658
|
+
},
|
|
84659
|
+
secondBarData: {
|
|
84660
|
+
text: "Final Check",
|
|
84661
|
+
status: "success",
|
|
84662
|
+
value: 0
|
|
84663
|
+
}
|
|
84664
|
+
}
|
|
84580
84665
|
},
|
|
84581
84666
|
{
|
|
84582
84667
|
id: "3",
|
|
@@ -84587,7 +84672,19 @@ const mockDataSource = {
|
|
|
84587
84672
|
nickname: "Store",
|
|
84588
84673
|
address: "789 Oak St"
|
|
84589
84674
|
},
|
|
84590
|
-
job_subtype: "delivery"
|
|
84675
|
+
job_subtype: "delivery",
|
|
84676
|
+
progress: {
|
|
84677
|
+
firstBarData: {
|
|
84678
|
+
text: "Pending",
|
|
84679
|
+
status: "info",
|
|
84680
|
+
value: 0
|
|
84681
|
+
},
|
|
84682
|
+
secondBarData: {
|
|
84683
|
+
text: "Awaiting",
|
|
84684
|
+
status: "success",
|
|
84685
|
+
value: 0
|
|
84686
|
+
}
|
|
84687
|
+
}
|
|
84591
84688
|
},
|
|
84592
84689
|
{
|
|
84593
84690
|
id: "4",
|
|
@@ -84598,7 +84695,19 @@ const mockDataSource = {
|
|
|
84598
84695
|
nickname: "Office",
|
|
84599
84696
|
address: "321 Pine St"
|
|
84600
84697
|
},
|
|
84601
|
-
job_subtype: "pickup"
|
|
84698
|
+
job_subtype: "pickup",
|
|
84699
|
+
progress: {
|
|
84700
|
+
firstBarData: {
|
|
84701
|
+
text: "In Progress",
|
|
84702
|
+
status: "info",
|
|
84703
|
+
value: 100
|
|
84704
|
+
},
|
|
84705
|
+
secondBarData: {
|
|
84706
|
+
text: "Validation",
|
|
84707
|
+
status: "success",
|
|
84708
|
+
value: 30
|
|
84709
|
+
}
|
|
84710
|
+
}
|
|
84602
84711
|
},
|
|
84603
84712
|
{
|
|
84604
84713
|
id: "5",
|
|
@@ -84609,7 +84718,19 @@ const mockDataSource = {
|
|
|
84609
84718
|
nickname: "Library",
|
|
84610
84719
|
address: "555 Book Lane"
|
|
84611
84720
|
},
|
|
84612
|
-
job_subtype: "delivery"
|
|
84721
|
+
job_subtype: "delivery",
|
|
84722
|
+
progress: {
|
|
84723
|
+
firstBarData: {
|
|
84724
|
+
text: "Completed",
|
|
84725
|
+
status: "info",
|
|
84726
|
+
value: 100
|
|
84727
|
+
},
|
|
84728
|
+
secondBarData: {
|
|
84729
|
+
text: "Verified",
|
|
84730
|
+
status: "success",
|
|
84731
|
+
value: 100
|
|
84732
|
+
}
|
|
84733
|
+
}
|
|
84613
84734
|
},
|
|
84614
84735
|
{
|
|
84615
84736
|
id: "6",
|
|
@@ -84620,7 +84741,19 @@ const mockDataSource = {
|
|
|
84620
84741
|
nickname: "Gym",
|
|
84621
84742
|
address: "777 Fitness Ave"
|
|
84622
84743
|
},
|
|
84623
|
-
job_subtype: "pickup"
|
|
84744
|
+
job_subtype: "pickup",
|
|
84745
|
+
progress: {
|
|
84746
|
+
firstBarData: {
|
|
84747
|
+
text: "Phase 1",
|
|
84748
|
+
status: "info",
|
|
84749
|
+
value: 75
|
|
84750
|
+
},
|
|
84751
|
+
secondBarData: {
|
|
84752
|
+
text: "Phase 2",
|
|
84753
|
+
status: "success",
|
|
84754
|
+
value: 50
|
|
84755
|
+
}
|
|
84756
|
+
}
|
|
84624
84757
|
},
|
|
84625
84758
|
{
|
|
84626
84759
|
id: "7",
|
|
@@ -84631,7 +84764,19 @@ const mockDataSource = {
|
|
|
84631
84764
|
nickname: "Mall",
|
|
84632
84765
|
address: "888 Shopping Center"
|
|
84633
84766
|
},
|
|
84634
|
-
job_subtype: "delivery"
|
|
84767
|
+
job_subtype: "delivery",
|
|
84768
|
+
progress: {
|
|
84769
|
+
firstBarData: {
|
|
84770
|
+
text: "Queued",
|
|
84771
|
+
status: "info",
|
|
84772
|
+
value: 0
|
|
84773
|
+
},
|
|
84774
|
+
secondBarData: {
|
|
84775
|
+
text: "Waiting",
|
|
84776
|
+
status: "success",
|
|
84777
|
+
value: 0
|
|
84778
|
+
}
|
|
84779
|
+
}
|
|
84635
84780
|
},
|
|
84636
84781
|
{
|
|
84637
84782
|
id: "8",
|
|
@@ -84642,7 +84787,19 @@ const mockDataSource = {
|
|
|
84642
84787
|
nickname: "School",
|
|
84643
84788
|
address: "999 Education Rd"
|
|
84644
84789
|
},
|
|
84645
|
-
job_subtype: "pickup"
|
|
84790
|
+
job_subtype: "pickup",
|
|
84791
|
+
progress: {
|
|
84792
|
+
firstBarData: {
|
|
84793
|
+
text: "Delivered",
|
|
84794
|
+
status: "info",
|
|
84795
|
+
value: 100
|
|
84796
|
+
},
|
|
84797
|
+
secondBarData: {
|
|
84798
|
+
text: "Confirmed",
|
|
84799
|
+
status: "success",
|
|
84800
|
+
value: 100
|
|
84801
|
+
}
|
|
84802
|
+
}
|
|
84646
84803
|
},
|
|
84647
84804
|
{
|
|
84648
84805
|
id: "9",
|
|
@@ -84653,7 +84810,19 @@ const mockDataSource = {
|
|
|
84653
84810
|
nickname: "Restaurant",
|
|
84654
84811
|
address: "111 Food Court"
|
|
84655
84812
|
},
|
|
84656
|
-
job_subtype: "delivery"
|
|
84813
|
+
job_subtype: "delivery",
|
|
84814
|
+
progress: {
|
|
84815
|
+
firstBarData: {
|
|
84816
|
+
text: "Preparing",
|
|
84817
|
+
status: "info",
|
|
84818
|
+
value: 100
|
|
84819
|
+
},
|
|
84820
|
+
secondBarData: {
|
|
84821
|
+
text: "Quality Check",
|
|
84822
|
+
status: "success",
|
|
84823
|
+
value: 15
|
|
84824
|
+
}
|
|
84825
|
+
}
|
|
84657
84826
|
},
|
|
84658
84827
|
{
|
|
84659
84828
|
id: "10",
|
|
@@ -84664,7 +84833,19 @@ const mockDataSource = {
|
|
|
84664
84833
|
nickname: "Park",
|
|
84665
84834
|
address: "222 Green Ave"
|
|
84666
84835
|
},
|
|
84667
|
-
job_subtype: "pickup"
|
|
84836
|
+
job_subtype: "pickup",
|
|
84837
|
+
progress: {
|
|
84838
|
+
firstBarData: {
|
|
84839
|
+
text: "Processing",
|
|
84840
|
+
status: "info",
|
|
84841
|
+
value: 80
|
|
84842
|
+
},
|
|
84843
|
+
secondBarData: {
|
|
84844
|
+
text: "Review",
|
|
84845
|
+
status: "success",
|
|
84846
|
+
value: 0
|
|
84847
|
+
}
|
|
84848
|
+
}
|
|
84668
84849
|
},
|
|
84669
84850
|
{
|
|
84670
84851
|
id: "11",
|