@stapel/listings-react 0.4.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (107) hide show
  1. package/CHANGELOG.md +102 -0
  2. package/dist/api/generated/schema.d.ts +2 -2
  3. package/dist/api/generated/schema.d.ts.map +1 -1
  4. package/dist/default/FavoritesPane.d.ts +40 -3
  5. package/dist/default/FavoritesPane.d.ts.map +1 -1
  6. package/dist/default/FavoritesPane.js +30 -18
  7. package/dist/default/FavoritesPane.js.map +1 -1
  8. package/dist/default/ListingCard.d.ts +25 -4
  9. package/dist/default/ListingCard.d.ts.map +1 -1
  10. package/dist/default/ListingCard.js +19 -12
  11. package/dist/default/ListingCard.js.map +1 -1
  12. package/dist/default/ListingComposerPage.d.ts +163 -23
  13. package/dist/default/ListingComposerPage.d.ts.map +1 -1
  14. package/dist/default/ListingComposerPage.js +85 -43
  15. package/dist/default/ListingComposerPage.js.map +1 -1
  16. package/dist/default/ListingDetailPane.d.ts +41 -4
  17. package/dist/default/ListingDetailPane.d.ts.map +1 -1
  18. package/dist/default/ListingDetailPane.js +38 -25
  19. package/dist/default/ListingDetailPane.js.map +1 -1
  20. package/dist/default/ListingPhoto.d.ts +13 -1
  21. package/dist/default/ListingPhoto.d.ts.map +1 -1
  22. package/dist/default/ListingPhoto.js +47 -9
  23. package/dist/default/ListingPhoto.js.map +1 -1
  24. package/dist/default/ListingPrice.d.ts +13 -0
  25. package/dist/default/ListingPrice.d.ts.map +1 -0
  26. package/dist/default/ListingPrice.js +60 -0
  27. package/dist/default/ListingPrice.js.map +1 -0
  28. package/dist/default/MyListingsPane.d.ts +7 -28
  29. package/dist/default/MyListingsPane.d.ts.map +1 -1
  30. package/dist/default/MyListingsPane.js +136 -67
  31. package/dist/default/MyListingsPane.js.map +1 -1
  32. package/dist/default/SignInLink.js +8 -7
  33. package/dist/default/SignInLink.js.map +1 -1
  34. package/dist/default/StatusTags.d.ts +16 -5
  35. package/dist/default/StatusTags.d.ts.map +1 -1
  36. package/dist/default/StatusTags.js +19 -13
  37. package/dist/default/StatusTags.js.map +1 -1
  38. package/dist/default/index.d.ts +15 -9
  39. package/dist/default/index.d.ts.map +1 -1
  40. package/dist/default/index.js +13 -6
  41. package/dist/default/index.js.map +1 -1
  42. package/dist/headless/Favorites.d.ts +6 -0
  43. package/dist/headless/Favorites.d.ts.map +1 -1
  44. package/dist/headless/Favorites.js +4 -0
  45. package/dist/headless/Favorites.js.map +1 -1
  46. package/dist/headless/ListingActions.d.ts +12 -0
  47. package/dist/headless/ListingActions.d.ts.map +1 -1
  48. package/dist/headless/ListingActions.js +3 -0
  49. package/dist/headless/ListingActions.js.map +1 -1
  50. package/dist/headless/ListingComposer.d.ts +23 -0
  51. package/dist/headless/ListingComposer.d.ts.map +1 -1
  52. package/dist/headless/ListingComposer.js +33 -7
  53. package/dist/headless/ListingComposer.js.map +1 -1
  54. package/dist/i18n/es.d.ts +6 -1
  55. package/dist/i18n/es.d.ts.map +1 -1
  56. package/dist/i18n/es.js +21 -4
  57. package/dist/i18n/es.js.map +1 -1
  58. package/dist/i18n/keys.d.ts +19 -2
  59. package/dist/i18n/keys.d.ts.map +1 -1
  60. package/dist/i18n/keys.js +35 -5
  61. package/dist/i18n/keys.js.map +1 -1
  62. package/dist/i18n/ru.d.ts +16 -1
  63. package/dist/i18n/ru.d.ts.map +1 -1
  64. package/dist/i18n/ru.js +33 -4
  65. package/dist/i18n/ru.js.map +1 -1
  66. package/dist/model/draft.d.ts +9 -6
  67. package/dist/model/draft.d.ts.map +1 -1
  68. package/dist/model/draft.js +3 -1
  69. package/dist/model/draft.js.map +1 -1
  70. package/dist/model/features.d.ts +21 -7
  71. package/dist/model/features.d.ts.map +1 -1
  72. package/dist/model/features.js +26 -0
  73. package/dist/model/features.js.map +1 -1
  74. package/llms.txt +7 -6
  75. package/manifest.json +53 -11
  76. package/nav-manifest.json +1 -1
  77. package/package.json +17 -12
  78. package/src/analytics/generated/events.json +1 -1
  79. package/src/api/generated/schema.ts +2 -2
  80. package/src/default/FavoritesPane.tsx +156 -82
  81. package/src/default/ListingCard.tsx +88 -46
  82. package/src/default/ListingComposerPage.tsx +403 -187
  83. package/src/default/ListingDetailPane.tsx +200 -98
  84. package/src/default/ListingPhoto.tsx +89 -16
  85. package/src/default/ListingPrice.tsx +77 -0
  86. package/src/default/MyListingsPane.tsx +286 -228
  87. package/src/default/SignInLink.tsx +4 -4
  88. package/src/default/StatusTags.tsx +36 -18
  89. package/src/default/index.ts +18 -7
  90. package/src/headless/Favorites.tsx +10 -0
  91. package/src/headless/ListingActions.tsx +19 -0
  92. package/src/headless/ListingComposer.tsx +56 -5
  93. package/src/i18n/es.ts +26 -4
  94. package/src/i18n/keys.ts +42 -5
  95. package/src/i18n/ru.ts +38 -4
  96. package/src/model/draft.ts +12 -7
  97. package/src/model/features.ts +48 -7
  98. package/dist/default/ErrorAlert.d.ts +0 -9
  99. package/dist/default/ErrorAlert.d.ts.map +0 -1
  100. package/dist/default/ErrorAlert.js +0 -27
  101. package/dist/default/ErrorAlert.js.map +0 -1
  102. package/dist/default/theme.d.ts +0 -25
  103. package/dist/default/theme.d.ts.map +0 -1
  104. package/dist/default/theme.js +0 -40
  105. package/dist/default/theme.js.map +0 -1
  106. package/src/default/ErrorAlert.tsx +0 -46
  107. package/src/default/theme.tsx +0 -67
@@ -1 +1 @@
1
- {"version":3,"file":"ListingCard.js","sourceRoot":"","sources":["../../src/default/ListingCard.tsx"],"names":[],"mappings":";AAkCA,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEnD,OAAO,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AAEjE,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AACrG,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,CAAC,QAAQ,CAAC,SAAS,CAAC,oBAC3B,MAAM,2BACC,8DAAyD,EAC/E,OAAO,EAAE,QAAQ,CAAC,MAAM,EACxB,IAAI,EAAE,KAAC,SAAS,IAAC,MAAM,EAAE,QAAQ,CAAC,SAAS,GAAI,GAC/C,IACG,CACR,GACY,CAChB,EAQA,KAAK,CAAC,YAAY,KAAK,KAAK;wBAC7B,YAAY,CAAC,MAAM,KAAK,SAAS;wBACjC,aAAa,KAAK,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAChC,KAAC,UAAU,CAAC,IAAI,IACd,IAAI,EAAC,WAAW,iBACJ,gCAAgC,YAE5C,KAAC,UAAU,IAAC,GAAG,EAAE,KAAK,CAAC,MAAM,EAAE,MAAM,EAAC,uBAAuB,GAAG,GAChD,CACnB,IACI,GACF,GACG,CACb,CAAC;AACJ,CAAC"}
@@ -1,32 +1,54 @@
1
1
  /**
2
2
  * `<ListingComposerPage>` — the submission screen.
3
3
  *
4
- * Four contracts meet on this page and each arrives through its own seam, so
4
+ * Five contracts meet on this page and each arrives through its own seam, so
5
5
  * the component can be read top to bottom without knowing any of the other
6
6
  * pairs:
7
7
  *
8
8
  * category `renderCategoryPicker` — the container's `<CategoryPickerField>`,
9
9
  * given `setCategory` to call
10
+ * where `locationPicker` — the container's `<LocationPickerField>`
11
+ * (`@stapel/geo-react`)
12
+ * currency `renderCurrencyPicker` — whatever vocabulary the deployment sells in
10
13
  * details `features` — the schema, drawn by `<FeatureFields>` (L0)
11
14
  * photos `gallerySlot` — the container's `<MediaGalleryField bag>`,
12
15
  * whose bag is handed here as `images`
13
16
  * the draft this pair
14
17
  *
15
- * ── Why the category slot is a render prop and not a node ──────────────────
18
+ * ── An unfilled slot is NAMED, never improvised ────────────────────────────
16
19
  *
17
- * It was a node (`categorySlot`), and a node cannot be mounted: the composer's
18
- * category moves only through `bag.setCategory`, and a `ReactNode` handed in
19
- * from outside has no way to reach it. There was no `onCategoryChange`either,
20
- * so a container could neither set the category nor learn itand `features`,
21
- * the schema of the chosen category, was therefore unreachable rather than
22
- * merely withheld. The screen could not be mounted at all (storefront Wave D,
23
- * named gap G-1).
20
+ * Every one of those four slots used to degrade into a control this pair could
21
+ * write on its own, and every one of those controls asked a question no seller
22
+ * can answer: a numeric category id typed into a text box, a currency CODE
23
+ * typed into a text box, and the defect the owner namedtwo decimal boxes
24
+ * labelled Latitude and Longitude. A gallery heading with nothing under it was
25
+ * the same defect with the improvisation left out.
24
26
  *
25
- * `renderCategoryPicker({ value, setCategory })` is the shape
26
- * `<CategoryPage renderListings>` already uses in the sibling pair, and the
27
- * controlled pair `category` / `onCategoryChange` is there for the container
28
- * that holds the id anyway it must, because the schema read
29
- * (`useCategoryFeatures(id)`) that fills `features` is keyed by it.
27
+ * So an unfilled slot renders `<SlotPlaceholder name="…"/>`: a labelled dashed
28
+ * region in a dev build, nothing at all in production. The rule is the one the
29
+ * rest of this codebase already lives by — `matchList`'s required empty arm,
30
+ * `ActionAvailability` with no "disabled for unknown reasons", `LoadState`
31
+ * refusing to fold failed into empty. A slot was the last place absence could
32
+ * still be silent, and `stapel/no-silent-slot` now says so at lint time.
33
+ *
34
+ * ── …and its LABEL goes with it ────────────────────────────────────────────
35
+ *
36
+ * The placeholder is nothing in production — but the `Form.Item` around it
37
+ * still drew its label, so a production composer with three unfilled slots
38
+ * rendered three labelled voids: "Category", "Currency", "Where it is" over
39
+ * empty space, and a "Photos" heading over air. A label is a promise that a
40
+ * control follows it. {@link SlotField} therefore renders the WHOLE field —
41
+ * label, help text and control — or nothing at all, and the `Photos` section
42
+ * does the same with its heading. `slotVisibility` pins the dev view on so a
43
+ * production-built showcase can still photograph the named placeholders.
44
+ *
45
+ * ── Why the pickers are slots and not dependencies ─────────────────────────
46
+ *
47
+ * A category tree, a geocoder and a currency vocabulary are all DEPLOYMENT
48
+ * knowledge, and all three live in sibling L2 pairs
49
+ * (`@stapel/categories-react`, `@stapel/geo-react`, the host's own). L2 pairs
50
+ * do not import each other; the container is the seam. A library that picked
51
+ * one would pick it for every host.
30
52
  *
31
53
  * ── Every blocked control says which of six reasons it is ──────────────────
32
54
  *
@@ -35,13 +57,20 @@
35
57
  * category asks for", "this build cannot draw one of these details", "wait
36
58
  * for the photos", "fix the highlighted fields" are six different problems
37
59
  * with six different next actions. `firstBlock` orders them the way a person
38
- * would be told, and the reason is rendered beside the button — never left
39
- * as a grey rectangle.
60
+ * would be told, and `<GatedButton>` renders the reason beside the button —
61
+ * never a grey rectangle, never a hover.
40
62
  */
41
- import type { ReactElement, ReactNode } from "react";
63
+ import type { ComponentType, ReactElement, ReactNode } from "react";
42
64
  import type { FeatureDef } from "@stapel/attributes-react";
65
+ import type { ListingLocation } from "../model/draft.js";
43
66
  import type { ListingImagesBag } from "../headless/ListingComposer.js";
44
67
  import type { ThemeModeProp } from "./types.js";
68
+ /**
69
+ * A form is read in one column, and a column has a width past which the eye
70
+ * loses the line — the reason a 2560px pane once rendered a 1640px Title box.
71
+ * A measure, not a pixel guess: `ch` scales with the type the theme is set to.
72
+ */
73
+ export declare const COMPOSER_MEASURE = "44rem";
45
74
  /**
46
75
  * What `renderCategoryPicker` is handed: the current category and the ONLY
47
76
  * function that changes it. Same shape as any other bag in this monorepo — the
@@ -54,6 +83,92 @@ export interface ComposerCategorySlot {
54
83
  * (one render later, once `features` arrives) and reports upwards. */
55
84
  readonly setCategory: (categoryId: string) => void;
56
85
  }
86
+ /**
87
+ * What `renderCurrencyPicker` is handed: the code the draft carries and the
88
+ * one function that changes it.
89
+ *
90
+ * The vocabulary is not this pair's: `Listing.currency` is a free
91
+ * `maxLength: 8` string on the wire (stapel-listings has no currency enum —
92
+ * the list lives in stapel-currencies), so the pair holds a DEFAULT from
93
+ * `createListingsRuntime` and asks the container for a chooser. Unfilled, the
94
+ * price field simply states which currency it is in.
95
+ */
96
+ export interface ComposerCurrencySlot {
97
+ /** ISO-4217-ish code, e.g. `"RUB"`. Never empty — the runtime's default. */
98
+ readonly value: string;
99
+ readonly setCurrency: (code: string) => void;
100
+ }
101
+ /**
102
+ * What a location picker component is handed — the contract
103
+ * `@stapel/geo-react`'s `<LocationPickerField>` was built to fill.
104
+ *
105
+ * `{ value, onChange }`, and `value` is the pin plus the address a resolver
106
+ * found for it. `lat`/`lon` are NUMBERS here (a picker works in numbers) while
107
+ * the draft keeps decimal STRINGS, because a float round-trips `55.796100`
108
+ * into `55.7961` and changes what was submitted; the conversion happens in
109
+ * this component, once, at the seam.
110
+ *
111
+ * Geo-react's own props are `value?: LatLon` and
112
+ * `onChange?: (picked: PickedLocation) => void`, so the adapter a container
113
+ * writes is three lines and no state:
114
+ *
115
+ * ```tsx
116
+ * import { LocationPickerField } from "@stapel/geo-react/default";
117
+ *
118
+ * <ListingComposerPage
119
+ * locationPicker={({ value, onChange }) => (
120
+ * <LocationPickerField
121
+ * {...(value.lat !== null && value.lon !== null
122
+ * ? { value: { lat: value.lat, lon: value.lon } }
123
+ * : {})}
124
+ * onChange={(picked) => {
125
+ * onChange({ lat: picked.point.lat, lon: picked.point.lon,
126
+ * address: picked.address ?? undefined });
127
+ * }}
128
+ * />
129
+ * )}
130
+ * />
131
+ * ```
132
+ *
133
+ * `geohash` is absent from this contract on purpose: since stapel-listings
134
+ * 0.7.1 the server computes it from the coordinates and ignores anything sent
135
+ * in the body, so a picker that has one has nowhere to put it and no reason
136
+ * to try (`model/draft.ts`).
137
+ */
138
+ export interface ComposerLocationValue {
139
+ /** Decimal degrees, or `null` when no place has been chosen yet. */
140
+ readonly lat: number | null;
141
+ readonly lon: number | null;
142
+ /** The one-line label a person reads: "Kazan, Vahitovsky district". */
143
+ readonly address?: string;
144
+ }
145
+ export interface ComposerLocationPickerProps {
146
+ readonly value: ComposerLocationValue;
147
+ readonly onChange: (next: ComposerLocationValue) => void;
148
+ }
149
+ /**
150
+ * The lower-level location seam: the WHOLE draft composite, and the `save`
151
+ * the plain fields call on blur.
152
+ *
153
+ * Kept beside {@link ComposerLocationPickerProps} for a host whose picker
154
+ * also resolves a `location_id` out of its own place directory — the id is
155
+ * this pair's wire field and no generic picker knows about it. A container
156
+ * that only has a pin and an address wants `locationPicker` instead.
157
+ */
158
+ export interface ComposerLocationSlot {
159
+ /** The location the draft currently carries. */
160
+ readonly value: ListingLocation;
161
+ /** Write the whole composite. `geohash` is read-only on the wire (0.7.1) —
162
+ * whatever is written here is kept for display and never sent. */
163
+ readonly setLocation: (location: ListingLocation) => void;
164
+ /**
165
+ * Persist the draft now. The plain fields save on blur, and a picker has no
166
+ * blur to speak of: choosing a suggestion IS the commit, so the slot is
167
+ * handed the same `save` those fields call rather than being left to hope
168
+ * the next unrelated blur carries its value.
169
+ */
170
+ readonly save: () => void;
171
+ }
57
172
  export interface ListingComposerPageProps extends ThemeModeProp {
58
173
  /** Editing an existing listing; absent for a new one. */
59
174
  readonly listingId?: number;
@@ -74,6 +189,9 @@ export interface ListingComposerPageProps extends ThemeModeProp {
74
189
  * />
75
190
  * )}
76
191
  * ```
192
+ *
193
+ * Unfilled: a named placeholder. The composer will NOT ask a person to type
194
+ * a category id.
77
195
  */
78
196
  readonly renderCategoryPicker?: (slot: ComposerCategorySlot) => ReactNode;
79
197
  /**
@@ -84,17 +202,39 @@ export interface ListingComposerPageProps extends ThemeModeProp {
84
202
  /** Called whenever the category changes, controlled or not. */
85
203
  readonly onCategoryChange?: (categoryId: string) => void;
86
204
  /**
87
- * @deprecated A node cannot reach `setCategory`, so a picker rendered into
88
- * this slot could never tell the composer what was chosen. Use
89
- * `renderCategoryPicker` (or the controlled `category` /
90
- * `onCategoryChange` pair). Still rendered, so nothing that passed it breaks.
205
+ * The currency chooser. Unfilled, the price field states the deployment's
206
+ * currency and nothing asks the seller to type a code.
207
+ */
208
+ readonly renderCurrencyPicker?: (slot: ComposerCurrencySlot) => ReactNode;
209
+ /**
210
+ * WHERE the thing is, asked the host's way — the slot
211
+ * `@stapel/geo-react`'s `<LocationPickerField>` fills (see
212
+ * {@link ComposerLocationPickerProps} for the three-line adapter).
213
+ *
214
+ * Unfilled: a named placeholder. The composer will NOT fall back to two
215
+ * decimal boxes — a seller does not know their latitude, and those boxes
216
+ * were the only reason `location` was ever left empty on this fleet.
217
+ */
218
+ readonly locationPicker?: ComponentType<ComposerLocationPickerProps>;
219
+ /**
220
+ * The whole-composite form of the same seam, for a picker that also resolves
221
+ * this pair's `location_id`. Wins over `locationPicker` when both are given.
91
222
  */
92
- readonly categorySlot?: ReactNode;
93
- /** The photo grid. Its bag is what `images` carries. */
223
+ readonly renderLocationPicker?: (slot: ComposerLocationSlot) => ReactNode;
224
+ /** The photo grid `@stapel/cdn-react`'s `<MediaGalleryField bag>`. Its bag
225
+ * is what `images` carries. Unfilled: a named placeholder, not a heading
226
+ * over nothing. */
94
227
  readonly gallerySlot?: ReactNode;
95
228
  /** `useUploadQueue()`'s bag from `@stapel/cdn-react` — `refs` becomes
96
229
  * `images_draft`, `settled` gates the submit. */
97
230
  readonly images?: ListingImagesBag;
231
+ /**
232
+ * Whether an unfilled slot shows its named placeholder. `"auto"` (default)
233
+ * follows the build: named in development, the whole field absent in
234
+ * production. `"visible"` pins it on — for a showcase built in production
235
+ * mode, which is the only way to photograph an integration defect.
236
+ */
237
+ readonly slotVisibility?: "auto" | "visible";
98
238
  readonly onPublished?: (listingId: number) => void;
99
239
  }
100
240
  export declare function ListingComposerPage(props: ListingComposerPageProps): ReactElement;
@@ -1 +1 @@
1
- {"version":3,"file":"ListingComposerPage.d.ts","sourceRoot":"","sources":["../../src/default/ListingComposerPage.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAcrD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAM3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAYvE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAA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AQ,CAAC,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7C,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;CACpD;AA2CD,wBAAgB,mBAAmB,CACjC,KAAK,EAAE,wBAAwB,GAC9B,YAAY,CAiad"}
@@ -1,18 +1,53 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Alert, Button, Checkbox, Divider, Flex, Form, Input, InputNumber, Space, Typography, } from "antd";
3
- import { useDescribeFlowError, useT } from "@stapel/core";
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Alert, Checkbox, Divider, Flex, Form, Input, InputNumber, Typography, } from "antd";
3
+ import { ErrorAlert, GatedButton, PaneGate, SkinTheme, } from "@stapel/tokens-antd/skin";
4
+ import { SlotPlaceholder, actionAvailable, isDevBuild, useDescribeFlowError, useI18n, useT, } from "@stapel/core";
5
+ import { spacing } from "@stapel/tokens";
4
6
  import { BUILTIN_VALUE_EDITOR_TYPES, FeatureFields, } from "@stapel/attributes-react/default";
5
7
  import { useListingComposer } from "../headless/ListingComposer.js";
6
8
  import { CATEGORY_FIELD, DESCRIPTION_FIELD, IMAGES_FIELD, PRICE_FIELD, TITLE_FIELD, failedResults, } from "../model/validation.js";
7
9
  import { LISTINGS_I18N_KEYS } from "../i18n/keys.js";
8
- import { ErrorAlert } from "./ErrorAlert.js";
9
- import { ListingsSkinTheme } from "./theme.js";
10
+ /**
11
+ * A form is read in one column, and a column has a width past which the eye
12
+ * loses the line — the reason a 2560px pane once rendered a 1640px Title box.
13
+ * A measure, not a pixel guess: `ch` scales with the type the theme is set to.
14
+ */
15
+ export const COMPOSER_MEASURE = "44rem";
16
+ /**
17
+ * A labelled field whose control comes from a slot — or NOTHING.
18
+ *
19
+ * The composer's orphan-field bug in one component: a `Form.Item` renders its
20
+ * label unconditionally, so an unfilled slot (which is `null` in a production
21
+ * build) left the label standing over empty space. Here the label and the
22
+ * control are one decision. `named` says whether the dev placeholder will
23
+ * draw; when it will not and the host filled nothing, the field is not part of
24
+ * the form at all.
25
+ */
26
+ function SlotField(props) {
27
+ const filled = props.control !== undefined;
28
+ if (!filled && !props.named)
29
+ return null;
30
+ return (_jsx(Form.Item, { label: props.label, ...(props.extra !== undefined ? { extra: props.extra } : {}), ...props.status, children: _jsx("div", { "data-testid": props.testId, children: props.control ?? _jsx(SlotPlaceholder, { name: props.slot, visibility: "visible" }) }) }));
31
+ }
32
+ /** A decimal string → the number a picker works in, or `null`. */
33
+ function toNumber(value) {
34
+ if (value === null || value.length === 0)
35
+ return null;
36
+ const parsed = Number(value);
37
+ return Number.isFinite(parsed) ? parsed : null;
38
+ }
10
39
  export function ListingComposerPage(props) {
11
40
  const t = useT();
41
+ const { locale } = useI18n();
12
42
  const describe = useDescribeFlowError();
13
43
  const bag = useListingComposer({
14
44
  ...(props.listingId !== undefined ? { listingId: props.listingId } : {}),
15
45
  features: props.features,
46
+ // A new draft carries the language it was WRITTEN in, and the only honest
47
+ // guess is the locale the composer is being read in. It was left empty and
48
+ // the server's default decided instead — a Spanish seller filing a listing
49
+ // stamped `ru` because that is the deployment default (gap L-9).
50
+ language: locale,
16
51
  ...(props.featuresLoading !== undefined
17
52
  ? { featuresLoading: props.featuresLoading }
18
53
  : {}),
@@ -47,49 +82,62 @@ export function ListingComposerPage(props) {
47
82
  const publishLabel = t(bag.isLiveEdit
48
83
  ? LISTINGS_I18N_KEYS.composeRepublish
49
84
  : LISTINGS_I18N_KEYS.composePublish);
50
- return (_jsx(ListingsSkinTheme, { ...(props.mode !== undefined ? { mode: props.mode } : {}), children: _jsxs(Flex, { vertical: true, gap: 16, "data-testid": "listings-composer", "data-stage": bag.stage, children: [_jsx(Typography.Title, { level: 3, children: t(props.listingId === undefined
85
+ const LocationPicker = props.locationPicker;
86
+ // Whether an unfilled slot draws its named placeholder — and therefore
87
+ // whether the field it belongs to exists at all.
88
+ const namedSlots = props.slotVisibility === "visible" || isDevBuild();
89
+ return (_jsx(SkinTheme, { surface: "base", style: { maxWidth: COMPOSER_MEASURE, padding: spacing[4] }, ...(props.mode !== undefined ? { mode: props.mode } : {}), children: _jsxs(Flex, { vertical: true, gap: spacing[4], "data-testid": "listings-composer", "data-stage": bag.stage, children: [_jsx(Typography.Title, { level: 3, children: t(props.listingId === undefined
51
90
  ? LISTINGS_I18N_KEYS.composeNewTitle
52
- : LISTINGS_I18N_KEYS.composeEditTitle) }), bag.draftNotReadable ? (_jsx(Alert, { type: "warning", showIcon: true, "data-testid": "listings-composer-draft-unreadable", message: t(LISTINGS_I18N_KEYS.composeBlockedNoDraft) })) : null, bag.outcome !== undefined ? (_jsx(Alert, { type: "success", showIcon: true, "data-testid": "listings-composer-published", "data-outcome": bag.outcome, message: t(bag.outcome === "live_edit_under_review"
91
+ : LISTINGS_I18N_KEYS.composeEditTitle) }), bag.draftNotReadable ? (_jsx(Alert, { type: "warning", showIcon: true, "data-testid": "listings-composer-draft-unreadable", title: t(LISTINGS_I18N_KEYS.composeBlockedNoDraft) })) : null, bag.outcome !== undefined ? (_jsx(Alert, { type: "success", showIcon: true, "data-testid": "listings-composer-published", "data-outcome": bag.outcome, title: t(bag.outcome === "live_edit_under_review"
53
92
  ? LISTINGS_I18N_KEYS.composePublishedLive
54
- : LISTINGS_I18N_KEYS.composePublishedFirst) })) : null, _jsxs(Form, { layout: "vertical", "data-testid": "listings-composer-form", children: [_jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeCategory), extra: t(LISTINGS_I18N_KEYS.composeCategoryHelp), ...errorOf(CATEGORY_FIELD), children: props.renderCategoryPicker !== undefined
55
- ? props.renderCategoryPicker({
56
- value: bag.values.categoryId,
57
- setCategory: bag.setCategory,
58
- })
59
- : (props.categorySlot ?? (_jsx(Input, { value: bag.values.categoryId, "aria-label": t(LISTINGS_I18N_KEYS.composeCategory), "data-testid": "listings-composer-category", onChange: (event) => {
60
- bag.setCategory(event.target.value);
61
- } }))) }), bag.droppedOnCategoryChange.length > 0 ? (_jsx(Alert, { type: "info", showIcon: true, "data-testid": "listings-composer-dropped", message: t(LISTINGS_I18N_KEYS.composeCategoryChangedDropped, {
93
+ : LISTINGS_I18N_KEYS.composePublishedFirst) })) : null, _jsxs(Form, { layout: "vertical", "data-testid": "listings-composer-form", children: [_jsx(SlotField, { label: t(LISTINGS_I18N_KEYS.composeCategory), extra: t(LISTINGS_I18N_KEYS.composeCategoryHelp), slot: "renderCategoryPicker", named: namedSlots, status: errorOf(CATEGORY_FIELD), testId: "listings-composer-category", control: props.renderCategoryPicker?.({
94
+ value: bag.values.categoryId,
95
+ setCategory: bag.setCategory,
96
+ }) }), bag.droppedOnCategoryChange.length > 0 ? (_jsx(Alert, { type: "info", showIcon: true, "data-testid": "listings-composer-dropped", title: t(LISTINGS_I18N_KEYS.composeCategoryChangedDropped, {
62
97
  count: bag.droppedOnCategoryChange.length,
63
98
  }) })) : null, _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeTitleLabel), ...errorOf(TITLE_FIELD), children: _jsx(Input, { value: bag.values.title, "aria-label": t(LISTINGS_I18N_KEYS.composeTitleLabel), "data-testid": "listings-composer-title", onChange: (event) => {
64
99
  bag.setValue("title", event.target.value);
65
100
  }, onBlur: bag.save }) }), _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeDescriptionLabel), ...errorOf(DESCRIPTION_FIELD), children: _jsx(Input.TextArea, { rows: 5, value: bag.values.description, "aria-label": t(LISTINGS_I18N_KEYS.composeDescriptionLabel), "data-testid": "listings-composer-description", onChange: (event) => {
66
101
  bag.setValue("description", event.target.value);
67
- }, onBlur: bag.save }) }), _jsxs(Space, { align: "start", wrap: true, children: [_jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composePriceLabel), ...errorOf(PRICE_FIELD), children: _jsx(Input, { inputMode: "decimal", value: bag.values.price, "aria-label": t(LISTINGS_I18N_KEYS.composePriceLabel), "data-testid": "listings-composer-price", onChange: (event) => {
68
- bag.setValue("price", event.target.value);
69
- }, onBlur: bag.save }) }), _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeCurrencyLabel), children: _jsx(Input, { value: bag.values.currency, "aria-label": t(LISTINGS_I18N_KEYS.composeCurrencyLabel), "data-testid": "listings-composer-currency", onChange: (event) => {
70
- bag.setValue("currency", event.target.value);
71
- }, onBlur: bag.save }) })] }), _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeLocationLabel), children: _jsx(Input, { value: bag.values.location.locationLabel, "aria-label": t(LISTINGS_I18N_KEYS.composeLocationLabel), "data-testid": "listings-composer-location", onChange: (event) => {
72
- bag.setLocation({
73
- ...bag.values.location,
74
- locationLabel: event.target.value,
75
- });
76
- }, onBlur: bag.save }) }), _jsxs(Space, { align: "start", wrap: true, children: [_jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeLatLabel), ...(bag.fieldErrors["location"] ? { validateStatus: "error" } : {}), children: _jsx(Input, { inputMode: "decimal", value: bag.values.location.lat ?? "", "aria-label": t(LISTINGS_I18N_KEYS.composeLatLabel), "data-testid": "listings-composer-lat", onChange: (event) => {
77
- bag.setLocation({
78
- ...bag.values.location,
79
- lat: event.target.value.length > 0 ? event.target.value : null,
80
- });
81
- }, onBlur: bag.save }) }), _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeLonLabel), ...errorOf("location"), children: _jsx(Input, { inputMode: "decimal", value: bag.values.location.lon ?? "", "aria-label": t(LISTINGS_I18N_KEYS.composeLonLabel), "data-testid": "listings-composer-lon", onChange: (event) => {
82
- bag.setLocation({
83
- ...bag.values.location,
84
- lon: event.target.value.length > 0 ? event.target.value : null,
85
- });
86
- }, onBlur: bag.save }) })] }), _jsx(Divider, {}), _jsx(Typography.Title, { level: 5, children: t(LISTINGS_I18N_KEYS.composePhotos) }), props.gallerySlot, bag.fieldErrors[IMAGES_FIELD] ? (_jsx(Typography.Text, { type: "danger", "data-testid": "listings-composer-images-error", children: describe(bag.fieldErrors[IMAGES_FIELD]).message })) : null, _jsx(Divider, {}), _jsx(Typography.Title, { level: 5, children: t(LISTINGS_I18N_KEYS.composeDetails) }), props.featuresError !== undefined ? (_jsx(Alert, { type: "error", showIcon: true, "data-testid": "listings-composer-features-failed", message: t(LISTINGS_I18N_KEYS.composeDetailsFailed) })) : props.featuresLoading === true ? (_jsx(Typography.Text, { type: "secondary", "data-testid": "listings-composer-features-loading", children: t(LISTINGS_I18N_KEYS.composeDetailsLoading) })) : props.features.length === 0 ? (_jsx(Typography.Text, { type: "secondary", "data-testid": "listings-composer-features-empty", children: t(LISTINGS_I18N_KEYS.composeDetailsEmpty) })) : (_jsx(FeatureFields, { features: props.features, values: bag.values.features, errors: bag.fieldErrors, disabled: bag.publishing, onChange: bag.setFeature })), _jsx(Divider, {}), _jsx(Form.Item, { children: _jsx(Checkbox, { checked: bag.values.countable, "data-testid": "listings-composer-countable", onChange: (event) => {
102
+ }, onBlur: bag.save }) }), _jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composePriceLabel), ...errorOf(PRICE_FIELD), children: _jsx(Input, { inputMode: "decimal", value: bag.values.price, ...(props.renderCurrencyPicker === undefined
103
+ ? { addonAfter: bag.values.currency }
104
+ : {}), "aria-label": t(LISTINGS_I18N_KEYS.composePriceLabel), "data-testid": "listings-composer-price", onChange: (event) => {
105
+ bag.setValue("price", event.target.value);
106
+ }, onBlur: bag.save }) }), _jsx(SlotField, { label: t(LISTINGS_I18N_KEYS.composeCurrencyLabel), slot: "renderCurrencyPicker", named: namedSlots, status: {}, testId: "listings-composer-currency", control: props.renderCurrencyPicker?.({
107
+ value: bag.values.currency,
108
+ setCurrency: (code) => {
109
+ bag.setValue("currency", code);
110
+ bag.saveSoon();
111
+ },
112
+ }) }), _jsx(SlotField, { label: t(LISTINGS_I18N_KEYS.composeLocationLabel), extra: t(LISTINGS_I18N_KEYS.composeLocationHelp), slot: "locationPicker", named: namedSlots, status: errorOf("location"), testId: "listings-composer-location", control: props.renderLocationPicker !== undefined ? (_jsx("div", { "data-testid": "listings-composer-location-slot", children: props.renderLocationPicker({
113
+ value: bag.values.location,
114
+ setLocation: (location) => {
115
+ bag.setLocation(location);
116
+ },
117
+ save: bag.saveSoon,
118
+ }) })) : LocationPicker !== undefined ? (_jsx("div", { "data-testid": "listings-composer-location-slot", children: _jsx(LocationPicker, { value: {
119
+ lat: toNumber(bag.values.location.lat),
120
+ lon: toNumber(bag.values.location.lon),
121
+ ...(bag.values.location.locationLabel.length > 0
122
+ ? { address: bag.values.location.locationLabel }
123
+ : {}),
124
+ }, onChange: (next) => {
125
+ // Numbers in, decimal strings out — the wire's spelling,
126
+ // written at the seam so no other module has to know.
127
+ bag.setLocation({
128
+ ...bag.values.location,
129
+ lat: next.lat === null ? null : String(next.lat),
130
+ lon: next.lon === null ? null : String(next.lon),
131
+ locationLabel: next.address ?? "",
132
+ });
133
+ bag.saveSoon();
134
+ } }) })) : undefined }), props.gallerySlot !== undefined || namedSlots ? (_jsxs(_Fragment, { children: [_jsx(Divider, {}), _jsx(Typography.Title, { level: 5, children: t(LISTINGS_I18N_KEYS.composePhotos) }), props.gallerySlot ?? (_jsx(SlotPlaceholder, { name: "gallerySlot", visibility: "visible" })), bag.fieldErrors[IMAGES_FIELD] ? (_jsx(Typography.Text, { type: "danger", "data-testid": "listings-composer-images-error", children: describe(bag.fieldErrors[IMAGES_FIELD]).message })) : null] })) : null, _jsx(Divider, {}), _jsx(Typography.Title, { level: 5, children: t(LISTINGS_I18N_KEYS.composeDetails) }), props.featuresError !== undefined ? (_jsx(ErrorAlert, { testId: "listings-composer-features-failed", message: t(LISTINGS_I18N_KEYS.composeDetailsFailed) })) : props.featuresLoading === true ? (_jsx(Typography.Text, { type: "secondary", "data-testid": "listings-composer-features-loading", children: t(LISTINGS_I18N_KEYS.composeDetailsLoading) })) : props.features.length === 0 ? (_jsx(Typography.Text, { type: "secondary", "data-testid": "listings-composer-features-empty", children: t(LISTINGS_I18N_KEYS.composeDetailsEmpty) })) : (_jsx(FeatureFields, { features: props.features, values: bag.values.features, errors: bag.fieldErrors, disabled: bag.publishing, onChange: bag.setFeature })), _jsx(Divider, {}), _jsx(Form.Item, { children: _jsx(Checkbox, { checked: bag.values.countable, "data-testid": "listings-composer-countable", onChange: (event) => {
87
135
  bag.setValue("countable", event.target.checked);
88
136
  }, children: t(LISTINGS_I18N_KEYS.composeCountable) }) }), bag.values.countable ? (_jsx(Form.Item, { label: t(LISTINGS_I18N_KEYS.composeStock), children: _jsx(InputNumber, { min: 0, value: bag.values.stockQuantity, "aria-label": t(LISTINGS_I18N_KEYS.composeStock), "data-testid": "listings-composer-stock", onChange: (value) => {
89
137
  bag.setValue("stockQuantity", value ?? null);
90
138
  } }) })) : null, _jsx(Form.Item, { children: _jsx(Checkbox, { checked: bag.values.autoRepublish, "data-testid": "listings-composer-auto-republish", onChange: (event) => {
91
139
  bag.setValue("autoRepublish", event.target.checked);
92
- }, children: t(LISTINGS_I18N_KEYS.composeAutoRepublish) }) })] }), bag.refusal?.kind === "invalid_draft" ? (_jsx(Alert, { type: "error", showIcon: true, "data-testid": "listings-composer-invalid", message: t(LISTINGS_I18N_KEYS.composeInvalidSummary, {
140
+ }, children: t(LISTINGS_I18N_KEYS.composeAutoRepublish) }) })] }), bag.refusal?.kind === "invalid_draft" ? (_jsx(ErrorAlert, { testId: "listings-composer-invalid", message: t(LISTINGS_I18N_KEYS.composeInvalidSummary, {
93
141
  count: failedResults(bag.refusal.batch).length,
94
142
  }) })) : null, bag.refusal?.kind === "error" ? (_jsx(ErrorAlert, { testId: "listings-composer-error", error: describe({
95
143
  code: bag.refusal.error.code,
@@ -97,12 +145,6 @@ export function ListingComposerPage(props) {
97
145
  status: bag.refusal.error.status,
98
146
  message: bag.refusal.error.message,
99
147
  language: bag.refusal.error.language,
100
- }) })) : null, bag.saveError !== undefined && bag.saveError !== null ? (_jsx(ErrorAlert, { testId: "listings-composer-save-error", error: describe({
101
- code: LISTINGS_I18N_KEYS.unknownError,
102
- params: {},
103
- status: 0,
104
- message: undefined,
105
- language: undefined,
106
- }) })) : null, _jsxs(Space, { children: [_jsx(Button, { disabled: !bag.saveGate.available, loading: bag.saving, "data-testid": "listings-composer-save", "data-analytics": "none", "data-analytics-reason": "business action \u2014 host app wraps with its own tracked()", onClick: bag.save, children: t(bag.saving ? LISTINGS_I18N_KEYS.composeSaving : LISTINGS_I18N_KEYS.composeSave) }), _jsx(Button, { type: "primary", disabled: !bag.publishGate.available, loading: bag.publishing, "data-testid": "listings-composer-publish", "data-analytics": "none", "data-analytics-reason": "business action \u2014 host app wraps with its own tracked()", onClick: bag.publish, children: bag.publishing ? t(LISTINGS_I18N_KEYS.composePublishing) : publishLabel }), bag.saved ? (_jsx(Typography.Text, { type: "success", "data-testid": "listings-composer-saved", children: t(LISTINGS_I18N_KEYS.composeSaved) })) : null] }), !bag.publishGate.available ? (_jsx(Typography.Text, { type: "secondary", "data-testid": "listings-composer-publish-blocked", children: t(bag.publishGate.block.code, bag.publishGate.block.params) })) : null] }) }));
148
+ }) })) : null, bag.saveError !== undefined && bag.saveError !== null ? (_jsx(ErrorAlert, { testId: "listings-composer-save-error", thrown: bag.saveError })) : null, _jsx(PaneGate, { gate: actionAvailable(), testId: "listings-composer-footer", children: _jsxs(Flex, { vertical: true, gap: spacing[3], align: "flex-start", children: [_jsx(GatedButton, { gate: bag.publishGate, type: "primary", size: "large", loading: bag.publishing, testId: "listings-composer-publish", "data-analytics": "none", "data-analytics-reason": "business action \u2014 host app wraps with its own tracked()", onClick: bag.publish, children: bag.publishing ? t(LISTINGS_I18N_KEYS.composePublishing) : publishLabel }), _jsxs(Flex, { gap: spacing[3], wrap: true, align: "flex-start", children: [_jsx(GatedButton, { gate: bag.saveGate, type: "text", loading: bag.saving, testId: "listings-composer-save", "data-analytics": "none", "data-analytics-reason": "business action \u2014 host app wraps with its own tracked()", onClick: bag.save, children: t(bag.saving ? LISTINGS_I18N_KEYS.composeSaving : LISTINGS_I18N_KEYS.composeSave) }), bag.saved ? (_jsx(Typography.Text, { type: "success", "data-testid": "listings-composer-saved", children: t(LISTINGS_I18N_KEYS.composeSaved) })) : null] })] }) })] }) }));
107
149
  }
108
150
  //# sourceMappingURL=ListingComposerPage.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ListingComposerPage.js","sourceRoot":"","sources":["../../src/default/ListingComposerPage.tsx"],"names":[],"mappings":";AAyCA,OAAO,EACL,KAAK,EACL,MAAM,EACN,QAAQ,EACR,OAAO,EACP,IAAI,EACJ,IAAI,EACJ,KAAK,EACL,WAAW,EACX,KAAK,EACL,UAAU,GACX,MAAM,MAAM,CAAC;AACd,OAAO,EAAE,oBAAoB,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAE1D,OAAO,EACL,0BAA0B,EAC1B,aAAa,GACd,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAEpE,OAAO,EACL,cAAc,EACd,iBAAiB,EACjB,YAAY,EACZ,WAAW,EACX,WAAW,EACX,aAAa,GACd,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AA4D/C,MAAM,UAAU,mBAAmB,CACjC,KAA+B;IAE/B,MAAM,CAAC,GAAG,IAAI,EAAE,CAAC;IACjB,MAAM,QAAQ,GAAG,oBAAoB,EAAE,CAAC;IACxC,MAAM,GAAG,GAAG,kBAAkB,CAAC;QAC7B,GAAG,CAAC,KAAK,CAAC,SAAS,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,KAAK,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACxE,QAAQ,EAAE,KAAK,CAAC,QAAQ;QACxB,GAAG,CAAC,KAAK,CAAC,eAAe,KAA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AAI,YAEhB,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,kBAAkB,CAAC,aAAa,CAAC,CAAC,CAAC,kBAAkB,CAAC,WAAW,CAAC,GAC3E,EAET,KAAC,MAAM,IACL,IAAI,EAAC,SAAS,EACd,QAAQ,EAAE,CAAC,GAAG,CAAC,WAAW,CAAC,SAAS,EACpC,OAAO,EAAE,GAAG,CAAC,UAAU,iBACX,2BAA2B,oBACxB,MAAM,2BACC,8DAAyD,EAC/E,OAAO,EAAE,GAAG,CAAC,OAAO,YAEnB,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,kBAAkB,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAC,YAAY,GACjE,EAER,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CACX,KAAC,UAAU,CAAC,IAAI,IAAC,IAAI,EAAC,SAAS,iBAAa,yBAAyB,YAClE,CAAC,CAAC,kBAAkB,CAAC,YAAY,CAAC,GACnB,CACnB,CAAC,CAAC,CAAC,IAAI,IACF,EAEP,CAAC,GAAG,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,CAAC,CAC5B,KAAC,UAAU,CAAC,IAAI,IAAC,IAAI,EAAC,WAAW,iBAAa,mCAAmC,YAC9E,CAAC,CAAC,GAAG,CAAC,WAAW,CAAC,KAAK,CAAC,IAAI,EAAE,GAAG,CAAC,WAAW,CAAC,KAAK,CAAC,MAAM,CAAC,GAC5C,CACnB,CAAC,CAAC,CAAC,IAAI,IACH,GACW,CACrB,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"ListingComposerPage.js","sourceRoot":"","sources":["../../src/default/ListingComposerPage.tsx"],"names":[],"mappings":";AA+DA,OAAO,EACL,KAAK,EACL,QAAQ,EACR,OAAO,EACP,IAAI,EACJ,IAAI,EACJ,KAAK,EACL,WAAW,EACX,UAAU,GACX,MAAM,MAAM,CAAC;AACd,OAAO,EACL,UAAU,EACV,WAAW,EACX,QAAQ,EACR,SA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AAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,kBAAkB,CAAC,aAAa,CAAC,CAAC,CAAC,kBAAkB,CAAC,WAAW,CAAC,GACtE,EAEb,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CACX,KAAC,UAAU,CAAC,IAAI,IAAC,IAAI,EAAC,SAAS,iBAAa,yBAAyB,YAClE,CAAC,CAAC,kBAAkB,CAAC,YAAY,CAAC,GACnB,CACnB,CAAC,CAAC,CAAC,IAAI,IACH,IACF,GACI,IACN,GACG,CACb,CAAC;AACJ,CAAC"}
@@ -1,5 +1,6 @@
1
1
  /**
2
- * `<ListingDetailPane>` — the listing page.
2
+ * `<ListingDetailPane>` — the listing page, and the page a marketplace makes
3
+ * its money on.
3
4
  *
4
5
  * Four distinct absences, four distinct sentences, and the whole point of the
5
6
  * component is that none of them collapses into another:
@@ -14,18 +15,54 @@
14
15
  * detail endpoint has no `published()` filter, so a draft answers 200 to
15
16
  * anyone holding the id. The pane says which side of that it is on rather
16
17
  * than dressing a draft up as a shop page.
18
+ *
19
+ * ── The page has ONE primary action, and it depends on who is reading ──────
20
+ *
21
+ * For two releases the only control here was "Save to favourites" — the money
22
+ * screen of a marketplace with no way to reach the seller, and the owner's own
23
+ * copy of the page offering to favourite their own listing. So:
24
+ *
25
+ * a buyer → `contactSlot` (the container's `@stapel/chat-react`
26
+ * "message the seller" button), with favouriting beside it as
27
+ * the secondary it always was;
28
+ * the owner → Edit and Take down, and no contact button at all — you do not
29
+ * message yourself.
30
+ *
31
+ * `contactSlot` is a SLOT because conversations belong to another L2 pair and
32
+ * L2 pairs do not import each other. Unfilled it renders `<SlotPlaceholder>`,
33
+ * so an app wired without a chat is a named gap in a dev build rather than a
34
+ * page whose only verb is "save".
17
35
  */
18
36
  import type { ReactElement, ReactNode } from "react";
19
37
  import type { ThemeModeProp } from "./types.js";
38
+ /** The reading measure of the page body. A detail page is prose plus a spec
39
+ * table; past this it stops being one column and starts being a stripe across
40
+ * a 2560px pane. */
41
+ export declare const DETAIL_MEASURE = "60rem";
42
+ /** The narrowest a gallery tile may get before the grid drops a column. A
43
+ * measure rather than a pixel: the tiles then fill whatever the ELEMENT is,
44
+ * which is §83's geometry rule — one photo per row on a phone, three on a
45
+ * desktop pane, and no `width: 320` that is near-full-bleed on one and a
46
+ * postage stamp on the other. */
47
+ export declare const DETAIL_PHOTO_MIN = "14rem";
20
48
  export interface ListingDetailPaneProps extends ThemeModeProp {
21
49
  readonly id: number;
22
50
  /** The reader's own uuid, when the host knows it. Enables the owner view —
23
51
  * the only place the moderation axis is shown, because it is the only
24
52
  * person it concerns. */
25
53
  readonly viewerId?: string;
26
- /** Slots the container fills: "message the seller" (chat-react), the
27
- * seller's profile link, reviews. Cross-pair navigation is the container's
28
- * job (spec §6.2 item 5), so this pair takes nodes rather than routes. */
54
+ /**
55
+ * THE primary action for a buyer: "message the seller", filled by the
56
+ * container from `@stapel/chat-react`. Rendered first, before favouriting,
57
+ * and never shown to the owner.
58
+ */
59
+ readonly contactSlot?: ReactNode;
60
+ /** Open the composer on this listing — the owner's primary. Absent is a real
61
+ * answer: the button then states that this app has no editing screen. */
62
+ readonly onEdit?: (id: number) => void;
63
+ /** Extra chrome beside the primary (the seller's profile link, a share
64
+ * button). Cross-pair navigation is the container's job (spec §6.2 item 5),
65
+ * so this pair takes nodes rather than routes. */
29
66
  readonly actions?: ReactNode;
30
67
  readonly footer?: ReactNode;
31
68
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ListingDetailPane.d.ts","sourceRoot":"","sources":["../../src/default/ListingDetailPane.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAarD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAEhD,MAAM,WAAW,sBAAuB,SAAQ,aAAa;IAC3D,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB;;6B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