@wix/editor-react-components 1.2518.0 → 1.2519.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.
@@ -0,0 +1,4 @@
1
+ declare const semanticClassNames: {
2
+ readonly root: "item-selection-test";
3
+ };
4
+ export default semanticClassNames;
@@ -0,0 +1,12 @@
1
+ import * as React from 'react';
2
+ export type ItemSelectionTestProps = {
3
+ id: string;
4
+ className?: string;
5
+ customClassNames?: Array<string>;
6
+ /** Selected contact id, written by the item-selection picker in the panel. */
7
+ contactId?: string;
8
+ /** Related contact names — the picker stores names directly (`itemField: NAME`). */
9
+ relatedContactNames?: Array<string>;
10
+ };
11
+ declare const ItemSelectionTest: React.FC<ItemSelectionTestProps>;
12
+ export default ItemSelectionTest;
@@ -0,0 +1,49 @@
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
+ import { c as clsx } from "../chunks/clsx.js";
3
+ import { f as formatClassNames } from "../chunks/classNames.js";
4
+ import { a as getDataAttributes } from "../chunks/dataUtils.js";
5
+ const semanticClassNames = {
6
+ root: "item-selection-test"
7
+ };
8
+ const root = "root__cGeS5";
9
+ const info = "info__sQLtB";
10
+ const name = "name__3kjVv";
11
+ const description = "description__iruxR";
12
+ const placeholder = "placeholder__kf4Vj";
13
+ const related = "related__EYp3Q";
14
+ const styles = {
15
+ root,
16
+ info,
17
+ name,
18
+ description,
19
+ placeholder,
20
+ related
21
+ };
22
+ const ItemSelectionTest = (props) => {
23
+ const {
24
+ id,
25
+ className,
26
+ customClassNames = [],
27
+ contactId,
28
+ relatedContactNames = []
29
+ } = props;
30
+ const rootClassName = clsx(
31
+ className,
32
+ styles.root,
33
+ formatClassNames(semanticClassNames.root, ...customClassNames),
34
+ "item-selection-test"
35
+ );
36
+ return /* @__PURE__ */ jsxs("div", { id, className: rootClassName, ...getDataAttributes(props), children: [
37
+ contactId ? /* @__PURE__ */ jsxs("div", { className: styles.info, children: [
38
+ /* @__PURE__ */ jsx("span", { className: styles.name, children: "Selected contact id" }),
39
+ /* @__PURE__ */ jsx("span", { className: styles.description, children: contactId })
40
+ ] }) : /* @__PURE__ */ jsx("div", { className: styles.placeholder, children: "Select a contact to feature" }),
41
+ relatedContactNames.length > 0 && /* @__PURE__ */ jsxs("div", { className: styles.related, children: [
42
+ "Related contacts — ",
43
+ relatedContactNames.join(", ")
44
+ ] })
45
+ ] });
46
+ };
47
+ export {
48
+ ItemSelectionTest as default
49
+ };
@@ -0,0 +1,13 @@
1
+ export declare const DisplayNames: {
2
+ readonly root: {
3
+ readonly elementDisplayName: "Item Selection (Test)";
4
+ readonly data: {
5
+ readonly contactId: "Contact";
6
+ readonly relatedContactNames: "Related contacts";
7
+ };
8
+ };
9
+ };
10
+ export declare const CONTACTS_PROVIDER_KEY = "74bff718-5977-47f2-9e5f-a9fd0047fd1f_ContactsItemsSelectionProvider";
11
+ export declare const presets: {
12
+ readonly default: "default";
13
+ };
@@ -0,0 +1,32 @@
1
+ .root__cGeS5 {
2
+ display: flex;
3
+ flex-direction: column;
4
+ gap: 12px;
5
+ padding: 16px;
6
+ box-sizing: border-box;
7
+ }
8
+
9
+ .info__sQLtB {
10
+ display: flex;
11
+ flex-direction: column;
12
+ gap: 4px;
13
+ min-width: 0;
14
+ }
15
+
16
+ .name__3kjVv {
17
+ font-weight: 600;
18
+ }
19
+
20
+ .description__iruxR {
21
+ opacity: 0.7;
22
+ }
23
+
24
+ .placeholder__kf4Vj {
25
+ opacity: 0.6;
26
+ padding: 16px;
27
+ }
28
+
29
+ .related__EYp3Q {
30
+ opacity: 0.7;
31
+ font-size: 0.875em;
32
+ }
@@ -0,0 +1,2 @@
1
+ export * from './component';
2
+ export { default, default as ItemSelectionTest } from './component';
@@ -0,0 +1,6 @@
1
+ 'use client';
2
+
3
+ import ItemSelectionTest from './component.js';
4
+
5
+ export { ItemSelectionTest };
6
+ export default ItemSelectionTest;
@@ -0,0 +1,5 @@
1
+ import { EditorReactComponent } from '@wix/component-protocol/schema';
2
+ declare const manifest: EditorReactComponent & {
3
+ id: string;
4
+ };
5
+ export default manifest;
@@ -0,0 +1,90 @@
1
+ import { L as LAYOUT, D as DATA, A as Archetype } from "../chunks/chunk-6KMOHX3X.js";
2
+ import { I as ItemField } from "../chunks/types.impl.js";
3
+ const DisplayNames = {
4
+ root: {
5
+ elementDisplayName: "Item Selection (Test)",
6
+ data: {
7
+ contactId: "Contact",
8
+ relatedContactNames: "Related contacts"
9
+ }
10
+ }
11
+ };
12
+ const CONTACTS_PROVIDER_KEY = "74bff718-5977-47f2-9e5f-a9fd0047fd1f_ContactsItemsSelectionProvider";
13
+ const presets = {
14
+ default: "default"
15
+ };
16
+ const manifest = {
17
+ id: "3a3a56a3-aaba-475e-b31f-a65054b188e2",
18
+ type: "wixEditorElements.ItemSelectionTest__DEV__v1",
19
+ description: "Test component for the item-selection picker infra — not exposed to users (TestComp convention).",
20
+ installation: {
21
+ presets: {
22
+ large: presets.default,
23
+ small: presets.default
24
+ }
25
+ },
26
+ resources: {
27
+ client: {
28
+ componentUrl: "./site/components/ItemSelectionTest/component.tsx"
29
+ }
30
+ },
31
+ editorElement: {
32
+ selector: ".item-selection-test",
33
+ displayName: DisplayNames.root.elementDisplayName,
34
+ archetype: Archetype.Text,
35
+ data: {
36
+ contactId: {
37
+ dataType: DATA.DATA_TYPE.text,
38
+ displayName: DisplayNames.root.data.contactId,
39
+ [DATA.DATA_TYPE.text]: {
40
+ itemSelection: {
41
+ providerKey: CONTACTS_PROVIDER_KEY,
42
+ maxSelected: 1,
43
+ itemField: ItemField.ID
44
+ }
45
+ }
46
+ },
47
+ relatedContactNames: {
48
+ dataType: DATA.DATA_TYPE.arrayItems,
49
+ displayName: DisplayNames.root.data.relatedContactNames,
50
+ [DATA.DATA_TYPE.arrayItems]: {
51
+ dataItem: {
52
+ dataType: DATA.DATA_TYPE.text,
53
+ [DATA.DATA_TYPE.text]: {
54
+ itemSelection: {
55
+ providerKey: CONTACTS_PROVIDER_KEY,
56
+ maxSelected: 3,
57
+ itemField: ItemField.NAME
58
+ }
59
+ }
60
+ }
61
+ }
62
+ }
63
+ },
64
+ presets: {
65
+ [presets.default]: {
66
+ presetCssUrl: `./site/components/ItemSelectionTest/presets/${presets.default}.css`,
67
+ displayName: DisplayNames.root.elementDisplayName,
68
+ initialSize: {
69
+ width: { sizingType: LAYOUT.SIZING_TYPE.pixels, pixels: 360 },
70
+ height: { sizingType: LAYOUT.SIZING_TYPE.content }
71
+ },
72
+ presetDefaults: {
73
+ layout: {
74
+ resizeDirection: LAYOUT.RESIZE_DIRECTION.horizontal,
75
+ contentResizeDirection: LAYOUT.CONTENT_RESIZE_DIRECTION.vertical,
76
+ disableStretching: false,
77
+ disablePositioning: false
78
+ }
79
+ }
80
+ }
81
+ }
82
+ },
83
+ moduleConfiguration: {
84
+ package: { name: "@wix/editor-react-components", version: "^1.0.0" },
85
+ component: { path: "site/components/ItemSelectionTest" }
86
+ }
87
+ };
88
+ export {
89
+ manifest as default
90
+ };
@@ -3119,5 +3119,6 @@ var ListStyle;
3119
3119
  export {
3120
3120
  DomEventType as D,
3121
3121
  FunctionRole as F,
3122
+ ItemField as I,
3122
3123
  VideoCategoryTypes as V
3123
3124
  };
@@ -1,21 +1,22 @@
1
1
  var _a, _b;
2
2
  import { extensions, app } from "@wix/astro/builders";
3
- import manifest$X from "./AccordionComponent/manifest.js";
4
- import manifest$W from "./AnimatedIcon/manifest.js";
5
- import manifest$V from "./AudioPlayer/manifest.js";
6
- import manifest$U from "./BoxContainer/manifest.js";
7
- import manifest$T from "./Breadcrumbs/manifest.js";
8
- import manifest$S from "./Button/manifest.js";
9
- import manifest$R from "./Checkbox/manifest.js";
10
- import manifest$Q from "./CheckboxGroup/manifest.js";
11
- import manifest$P from "./CollapsibleText/manifest.js";
12
- import manifest$O from "./DatePicker/manifest.js";
13
- import manifest$N from "./Dropdown/manifest.js";
14
- import manifest$M from "./GoogleMap/manifest.js";
15
- import manifest$L from "./HipaaIcon/manifest.js";
3
+ import manifest$Y from "./AccordionComponent/manifest.js";
4
+ import manifest$X from "./AnimatedIcon/manifest.js";
5
+ import manifest$W from "./AudioPlayer/manifest.js";
6
+ import manifest$V from "./BoxContainer/manifest.js";
7
+ import manifest$U from "./Breadcrumbs/manifest.js";
8
+ import manifest$T from "./Button/manifest.js";
9
+ import manifest$S from "./Checkbox/manifest.js";
10
+ import manifest$R from "./CheckboxGroup/manifest.js";
11
+ import manifest$Q from "./CollapsibleText/manifest.js";
12
+ import manifest$P from "./DatePicker/manifest.js";
13
+ import manifest$O from "./Dropdown/manifest.js";
14
+ import manifest$N from "./GoogleMap/manifest.js";
15
+ import manifest$M from "./HipaaIcon/manifest.js";
16
16
  import { H as HIPAA_SETTINGS_PANEL_ID } from "./chunks/constants31.js";
17
- import manifest$K from "./HTMLComponent/manifest.js";
18
- import manifest$J from "./Image3/manifest.js";
17
+ import manifest$L from "./HTMLComponent/manifest.js";
18
+ import manifest$K from "./Image3/manifest.js";
19
+ import manifest$J from "./ItemSelectionTest/manifest.js";
19
20
  import manifest$I from "./LegacyAppWidget/manifest.js";
20
21
  import manifest$H from "./LegacyContainer/manifest.js";
21
22
  import manifest$G from "./LegacyMultiStateBox/manifest.js";
@@ -482,21 +483,22 @@ const videoUploadPanelExtension = extensions.editorReactComponentPanel({
482
483
  }
483
484
  });
484
485
  const componentManifests = {
485
- AccordionComponent: manifest$X,
486
- AnimatedIcon: manifest$W,
487
- AudioPlayer: manifest$V,
488
- BoxContainer: manifest$U,
489
- Breadcrumbs: manifest$T,
490
- Button: manifest$S,
491
- Checkbox: manifest$R,
492
- CheckboxGroup: manifest$Q,
493
- CollapsibleText: manifest$P,
494
- DatePicker: manifest$O,
495
- Dropdown: manifest$N,
496
- GoogleMap: manifest$M,
497
- HipaaIcon: manifest$L,
498
- HTMLComponent: manifest$K,
499
- Image3: manifest$J,
486
+ AccordionComponent: manifest$Y,
487
+ AnimatedIcon: manifest$X,
488
+ AudioPlayer: manifest$W,
489
+ BoxContainer: manifest$V,
490
+ Breadcrumbs: manifest$U,
491
+ Button: manifest$T,
492
+ Checkbox: manifest$S,
493
+ CheckboxGroup: manifest$R,
494
+ CollapsibleText: manifest$Q,
495
+ DatePicker: manifest$P,
496
+ Dropdown: manifest$O,
497
+ GoogleMap: manifest$N,
498
+ HipaaIcon: manifest$M,
499
+ HTMLComponent: manifest$L,
500
+ Image3: manifest$K,
501
+ ItemSelectionTest: manifest$J,
500
502
  LegacyAppWidget: manifest$I,
501
503
  LegacyContainer: manifest$H,
502
504
  LegacyMultiStateBox: manifest$G,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/editor-react-components",
3
- "version": "1.2518.0",
3
+ "version": "1.2519.0",
4
4
  "description": "React components for the Wix Editor",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -53,7 +53,7 @@
53
53
  "test:e2e:ci": "tsx scripts/wait-for-preview-readiness.ts && sled-playwright test --config=playwright.livesite.config.ts",
54
54
  "test:detect-flakiness": "yarn build:lite && sled-playwright detect-flakiness --config=playwright.livesite.config.ts --path e2e/livesites/tests --repeat-count 20",
55
55
  "check-a11y-coverage": "a11y-check-coverage --warn-only",
56
- "tsc": "npx tsc -b ./tsconfig.json --force",
56
+ "tsc": "node ../../scripts/run-tsc7.js -b ./tsconfig.json",
57
57
  "prepare:manifest-tests": "yarn validate:manifests && yarn generate:manifest-tests",
58
58
  "build:janet": "yarn build-storybook && janet-build",
59
59
  "test:coverage": "vitest run --coverage",
@@ -82,7 +82,7 @@
82
82
  "@wix/sdk": "^1.21.15",
83
83
  "@wix/services-manager-react": "^0.1.27",
84
84
  "@wix/site-service-rendering-context": "^1.0.1",
85
- "@wix/site-ui": "1.230.0",
85
+ "@wix/site-ui": "1.231.0",
86
86
  "@wix/video": "^1.106.0",
87
87
  "@wix/viewer-service-consent-policy": "^1.0.101",
88
88
  "@wix/web-bi-logger": "^2.1.29",
@@ -197,5 +197,5 @@
197
197
  "registry": "https://registry.npmjs.org/",
198
198
  "access": "public"
199
199
  },
200
- "falconPackageHash": "bf859fd1cc36cbc4e9cd924d4e5a0c59ac4e9ac9fe182e46f1e5e8fc"
200
+ "falconPackageHash": "c4a2cc5f486b5088f05cb965375ab7cb3c4db5aca0b7e0f79aefb750"
201
201
  }