@tbox.cn/app-module-parking 1.0.0-alpha.1 → 1.0.0-alpha.10

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.
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  cards,
3
3
  clientModule
4
- } from "../chunk-SI5NHAIK.js";
4
+ } from "../chunk-A5CEUOLD.js";
5
5
  export {
6
6
  clientModule,
7
7
  cards as parkingClientCards
package/dist/index.js CHANGED
@@ -10,7 +10,7 @@ import {
10
10
  import {
11
11
  cards,
12
12
  clientModule
13
- } from "./chunk-SI5NHAIK.js";
13
+ } from "./chunk-A5CEUOLD.js";
14
14
  export {
15
15
  InMemoryParkingService,
16
16
  clientModule,
@@ -107,9 +107,9 @@ declare const parkingCards: {
107
107
  membership: zod.ZodOptional<zod.ZodObject<{
108
108
  state: zod.ZodEnum<["unauthenticated", "unknown", "active", "not_enrolled", "closed", "unavailable"]>;
109
109
  }, "strip", zod.ZodTypeAny, {
110
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
110
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
111
111
  }, {
112
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
112
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
113
113
  }>>;
114
114
  }, "strip", zod.ZodTypeAny, {
115
115
  bound: {
@@ -119,7 +119,7 @@ declare const parkingCards: {
119
119
  }[];
120
120
  message?: string | undefined;
121
121
  membership?: {
122
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
122
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
123
123
  } | undefined;
124
124
  }, {
125
125
  bound: {
@@ -129,7 +129,7 @@ declare const parkingCards: {
129
129
  }[];
130
130
  message?: string | undefined;
131
131
  membership?: {
132
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
132
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
133
133
  } | undefined;
134
134
  }>>;
135
135
  readonly 'parking-info': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
@@ -150,15 +150,15 @@ declare const parkingCards: {
150
150
  value: string;
151
151
  label: string;
152
152
  }[];
153
- kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
154
153
  title: string;
154
+ kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
155
155
  }, {
156
156
  entries: {
157
157
  value: string;
158
158
  label: string;
159
159
  }[];
160
- kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
161
160
  title: string;
161
+ kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
162
162
  }>>;
163
163
  readonly 'parking-payment': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
164
164
  quoteRef: zod.ZodString;
@@ -182,10 +182,10 @@ declare const parkingCards: {
182
182
  state: zod.ZodEnum<["unauthenticated", "unknown", "active", "not_enrolled", "closed", "unavailable"]>;
183
183
  availablePoints: zod.ZodOptional<zod.ZodNumber>;
184
184
  }, "strip", zod.ZodTypeAny, {
185
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
185
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
186
186
  availablePoints?: number | undefined;
187
187
  }, {
188
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
188
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
189
189
  availablePoints?: number | undefined;
190
190
  }>>;
191
191
  paymentOptions: zod.ZodOptional<zod.ZodObject<{
@@ -219,12 +219,12 @@ declare const parkingCards: {
219
219
  title: zod.ZodString;
220
220
  benefitRefs: zod.ZodArray<zod.ZodString, "many">;
221
221
  }, "strip", zod.ZodTypeAny, {
222
- kind: "requires_reprice";
223
222
  title: string;
223
+ kind: "requires_reprice";
224
224
  benefitRefs: string[];
225
225
  }, {
226
- kind: "requires_reprice";
227
226
  title: string;
227
+ kind: "requires_reprice";
228
228
  benefitRefs: string[];
229
229
  }>]>>;
230
230
  }, "strip", zod.ZodTypeAny, {
@@ -238,8 +238,8 @@ declare const parkingCards: {
238
238
  benefitRefs: string[];
239
239
  pointsToUse: number;
240
240
  } | {
241
- kind: "requires_reprice";
242
241
  title: string;
242
+ kind: "requires_reprice";
243
243
  benefitRefs: string[];
244
244
  } | undefined;
245
245
  }, {
@@ -253,8 +253,8 @@ declare const parkingCards: {
253
253
  benefitRefs: string[];
254
254
  pointsToUse: number;
255
255
  } | {
256
- kind: "requires_reprice";
257
256
  title: string;
257
+ kind: "requires_reprice";
258
258
  benefitRefs: string[];
259
259
  } | undefined;
260
260
  }>>;
@@ -403,7 +403,7 @@ declare const parkingCards: {
403
403
  durationText?: string | undefined;
404
404
  discountText?: string | undefined;
405
405
  membership?: {
406
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
406
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
407
407
  availablePoints?: number | undefined;
408
408
  } | undefined;
409
409
  paymentOptions?: {
@@ -417,8 +417,8 @@ declare const parkingCards: {
417
417
  benefitRefs: string[];
418
418
  pointsToUse: number;
419
419
  } | {
420
- kind: "requires_reprice";
421
420
  title: string;
421
+ kind: "requires_reprice";
422
422
  benefitRefs: string[];
423
423
  } | undefined;
424
424
  } | undefined;
@@ -471,7 +471,7 @@ declare const parkingCards: {
471
471
  durationText?: string | undefined;
472
472
  discountText?: string | undefined;
473
473
  membership?: {
474
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
474
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
475
475
  availablePoints?: number | undefined;
476
476
  } | undefined;
477
477
  paymentOptions?: {
@@ -485,8 +485,8 @@ declare const parkingCards: {
485
485
  benefitRefs: string[];
486
486
  pointsToUse: number;
487
487
  } | {
488
- kind: "requires_reprice";
489
488
  title: string;
489
+ kind: "requires_reprice";
490
490
  benefitRefs: string[];
491
491
  } | undefined;
492
492
  } | undefined;
@@ -606,8 +606,6 @@ declare const parkingCards: {
606
606
  caveats: zod.ZodArray<zod.ZodString, "many">;
607
607
  message: zod.ZodOptional<zod.ZodString>;
608
608
  }, "strip", zod.ZodTypeAny, {
609
- total: number;
610
- hasMore: boolean;
611
609
  items: {
612
610
  status: "UNKNOWN" | "PAID" | "REFUNDED" | "CLOSED";
613
611
  plateNo: string;
@@ -624,11 +622,11 @@ declare const parkingCards: {
624
622
  invoiceEligible?: boolean | undefined;
625
623
  invoiceIssued?: boolean | undefined;
626
624
  }[];
625
+ total: number;
626
+ hasMore: boolean;
627
627
  caveats: string[];
628
628
  message?: string | undefined;
629
629
  }, {
630
- total: number;
631
- hasMore: boolean;
632
630
  items: {
633
631
  status: "UNKNOWN" | "PAID" | "REFUNDED" | "CLOSED";
634
632
  plateNo: string;
@@ -645,6 +643,8 @@ declare const parkingCards: {
645
643
  invoiceEligible?: boolean | undefined;
646
644
  invoiceIssued?: boolean | undefined;
647
645
  }[];
646
+ total: number;
647
+ hasMore: boolean;
648
648
  caveats: string[];
649
649
  message?: string | undefined;
650
650
  }>>;
@@ -678,10 +678,10 @@ declare const serverModule: {
678
678
  state: zod.ZodEnum<["unauthenticated", "unknown", "active", "not_enrolled", "closed", "unavailable"]>;
679
679
  availablePoints: zod.ZodOptional<zod.ZodNumber>;
680
680
  }, "strip", zod.ZodTypeAny, {
681
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
681
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
682
682
  availablePoints?: number | undefined;
683
683
  }, {
684
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
684
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
685
685
  availablePoints?: number | undefined;
686
686
  }>>;
687
687
  paymentOptions: zod.ZodOptional<zod.ZodObject<{
@@ -715,12 +715,12 @@ declare const serverModule: {
715
715
  title: zod.ZodString;
716
716
  benefitRefs: zod.ZodArray<zod.ZodString, "many">;
717
717
  }, "strip", zod.ZodTypeAny, {
718
- kind: "requires_reprice";
719
718
  title: string;
719
+ kind: "requires_reprice";
720
720
  benefitRefs: string[];
721
721
  }, {
722
- kind: "requires_reprice";
723
722
  title: string;
723
+ kind: "requires_reprice";
724
724
  benefitRefs: string[];
725
725
  }>]>>;
726
726
  }, "strip", zod.ZodTypeAny, {
@@ -734,8 +734,8 @@ declare const serverModule: {
734
734
  benefitRefs: string[];
735
735
  pointsToUse: number;
736
736
  } | {
737
- kind: "requires_reprice";
738
737
  title: string;
738
+ kind: "requires_reprice";
739
739
  benefitRefs: string[];
740
740
  } | undefined;
741
741
  }, {
@@ -749,8 +749,8 @@ declare const serverModule: {
749
749
  benefitRefs: string[];
750
750
  pointsToUse: number;
751
751
  } | {
752
- kind: "requires_reprice";
753
752
  title: string;
753
+ kind: "requires_reprice";
754
754
  benefitRefs: string[];
755
755
  } | undefined;
756
756
  }>>;
@@ -899,7 +899,7 @@ declare const serverModule: {
899
899
  durationText?: string | undefined;
900
900
  discountText?: string | undefined;
901
901
  membership?: {
902
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
902
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
903
903
  availablePoints?: number | undefined;
904
904
  } | undefined;
905
905
  paymentOptions?: {
@@ -913,8 +913,8 @@ declare const serverModule: {
913
913
  benefitRefs: string[];
914
914
  pointsToUse: number;
915
915
  } | {
916
- kind: "requires_reprice";
917
916
  title: string;
917
+ kind: "requires_reprice";
918
918
  benefitRefs: string[];
919
919
  } | undefined;
920
920
  } | undefined;
@@ -967,7 +967,7 @@ declare const serverModule: {
967
967
  durationText?: string | undefined;
968
968
  discountText?: string | undefined;
969
969
  membership?: {
970
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
970
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
971
971
  availablePoints?: number | undefined;
972
972
  } | undefined;
973
973
  paymentOptions?: {
@@ -981,8 +981,8 @@ declare const serverModule: {
981
981
  benefitRefs: string[];
982
982
  pointsToUse: number;
983
983
  } | {
984
- kind: "requires_reprice";
985
984
  title: string;
985
+ kind: "requires_reprice";
986
986
  benefitRefs: string[];
987
987
  } | undefined;
988
988
  } | undefined;
@@ -1102,8 +1102,6 @@ declare const serverModule: {
1102
1102
  caveats: zod.ZodArray<zod.ZodString, "many">;
1103
1103
  message: zod.ZodOptional<zod.ZodString>;
1104
1104
  }, "strip", zod.ZodTypeAny, {
1105
- total: number;
1106
- hasMore: boolean;
1107
1105
  items: {
1108
1106
  status: "UNKNOWN" | "PAID" | "REFUNDED" | "CLOSED";
1109
1107
  plateNo: string;
@@ -1120,11 +1118,11 @@ declare const serverModule: {
1120
1118
  invoiceEligible?: boolean | undefined;
1121
1119
  invoiceIssued?: boolean | undefined;
1122
1120
  }[];
1121
+ total: number;
1122
+ hasMore: boolean;
1123
1123
  caveats: string[];
1124
1124
  message?: string | undefined;
1125
1125
  }, {
1126
- total: number;
1127
- hasMore: boolean;
1128
1126
  items: {
1129
1127
  status: "UNKNOWN" | "PAID" | "REFUNDED" | "CLOSED";
1130
1128
  plateNo: string;
@@ -1141,6 +1139,8 @@ declare const serverModule: {
1141
1139
  invoiceEligible?: boolean | undefined;
1142
1140
  invoiceIssued?: boolean | undefined;
1143
1141
  }[];
1142
+ total: number;
1143
+ hasMore: boolean;
1144
1144
  caveats: string[];
1145
1145
  message?: string | undefined;
1146
1146
  }>>;
@@ -1162,9 +1162,9 @@ declare const serverModule: {
1162
1162
  membership: zod.ZodOptional<zod.ZodObject<{
1163
1163
  state: zod.ZodEnum<["unauthenticated", "unknown", "active", "not_enrolled", "closed", "unavailable"]>;
1164
1164
  }, "strip", zod.ZodTypeAny, {
1165
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
1165
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
1166
1166
  }, {
1167
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
1167
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
1168
1168
  }>>;
1169
1169
  }, "strip", zod.ZodTypeAny, {
1170
1170
  bound: {
@@ -1174,7 +1174,7 @@ declare const serverModule: {
1174
1174
  }[];
1175
1175
  message?: string | undefined;
1176
1176
  membership?: {
1177
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
1177
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
1178
1178
  } | undefined;
1179
1179
  }, {
1180
1180
  bound: {
@@ -1184,7 +1184,7 @@ declare const serverModule: {
1184
1184
  }[];
1185
1185
  message?: string | undefined;
1186
1186
  membership?: {
1187
- state: "unknown" | "unavailable" | "unauthenticated" | "active" | "not_enrolled" | "closed";
1187
+ state: "unknown" | "unavailable" | "active" | "unauthenticated" | "not_enrolled" | "closed";
1188
1188
  } | undefined;
1189
1189
  }>>;
1190
1190
  readonly 'parking-info': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
@@ -1205,15 +1205,15 @@ declare const serverModule: {
1205
1205
  value: string;
1206
1206
  label: string;
1207
1207
  }[];
1208
- kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
1209
1208
  title: string;
1209
+ kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
1210
1210
  }, {
1211
1211
  entries: {
1212
1212
  value: string;
1213
1213
  label: string;
1214
1214
  }[];
1215
- kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
1216
1215
  title: string;
1216
+ kind: "chargeRules" | "benefitPolicy" | "vehicleLocation";
1217
1217
  }>>;
1218
1218
  };
1219
1219
  skills: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tbox.cn/app-module-parking",
3
- "version": "1.0.0-alpha.1",
3
+ "version": "1.0.0-alpha.10",
4
4
  "type": "module",
5
5
  "description": "商圈停车模块:计费支付、车辆寻车、缴费记录与开票(codegen 源)。",
6
6
  "exports": {
@@ -18,15 +18,16 @@
18
18
  }
19
19
  },
20
20
  "dependencies": {
21
- "@tbox.cn/app-contracts": "1.0.0-alpha.1",
22
- "@tbox.cn/app-contracts-mall": "1.0.0-alpha.1",
23
- "@tbox.cn/app-agent-sdk-client": "1.0.0-alpha.1",
24
- "@tbox.cn/app-agent-sdk-server": "1.0.0-alpha.1"
21
+ "@tbox.cn/app-contracts": "1.0.0-alpha.10",
22
+ "@tbox.cn/app-agent-sdk-client": "1.0.0-alpha.10",
23
+ "@tbox.cn/app-agent-sdk-server": "1.0.0-alpha.10",
24
+ "@tbox.cn/app-contracts-mall": "1.0.0-alpha.10"
25
25
  },
26
26
  "peerDependencies": {
27
27
  "zod": "3.25.76",
28
28
  "react": "18.3.1",
29
- "@phosphor-icons/react": "2.1.10"
29
+ "@phosphor-icons/react": "2.1.10",
30
+ "@tbox.cn/app-agent-ui-kit": "^1.0.0-alpha.10"
30
31
  },
31
32
  "devDependencies": {
32
33
  "@types/react": "18.3.31",
@@ -59,9 +60,11 @@
59
60
  "access": "public"
60
61
  },
61
62
  "license": "MIT",
62
- "sideEffects": [
63
- "**/*.css"
64
- ],
63
+ "peerDependenciesMeta": {
64
+ "@tbox.cn/app-agent-ui-kit": {
65
+ "optional": true
66
+ }
67
+ },
65
68
  "scripts": {
66
69
  "typecheck": "tsc --noEmit",
67
70
  "test": "vitest run",
@@ -16,21 +16,21 @@ export function ParkingInfoCard(props: { data: ParkingInfoCardData }) {
16
16
  const { data } = props;
17
17
  const { subtitle, Icon } = KIND_META[data.kind];
18
18
  return (
19
- <section className="parking-info">
20
- <header className="parking-info__head">
21
- <span className="parking-info__head-icon">
19
+ <section className="parking-info w-full bg-card p-3.5 text-foreground">
20
+ <header className="parking-info__head mb-3 flex items-center gap-2">
21
+ <span className="parking-info__head-icon grid size-8 shrink-0 place-items-center rounded-md bg-primary-soft text-primary">
22
22
  <Icon weight="duotone" size={24} />
23
23
  </span>
24
- <div className="parking-info__heading">
25
- <h4>{data.title}</h4>
26
- <p>{subtitle}</p>
24
+ <div className="parking-info__heading flex min-w-0 flex-col">
25
+ <h4 className="truncate text-base font-bold leading-5.5 text-foreground">{data.title}</h4>
26
+ <p className="mt-1 text-xs leading-4 text-secondary-foreground">{subtitle}</p>
27
27
  </div>
28
28
  </header>
29
- <dl className="parking-info__entries">
29
+ <dl className="parking-info__entries grid gap-1.5">
30
30
  {data.entries.map((e) => (
31
- <div key={e.label} className="parking-info__entry">
32
- <dt>{e.label}</dt>
33
- <dd>{e.value}</dd>
31
+ <div key={e.label} className="parking-info__entry flex justify-between gap-2.5 rounded-md border-2 border-border bg-muted px-2.5 py-2.25 text-xs leading-4.5">
32
+ <dt className="shrink-0 text-secondary-foreground">{e.label}</dt>
33
+ <dd className="text-right font-medium break-words text-foreground">{e.value}</dd>
34
34
  </div>
35
35
  ))}
36
36
  </dl>