@wix/editor-react-components 1.2548.0 → 1.2550.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.
@@ -52,4 +52,5 @@ export type CopyButtonWrapperComponentProps = {
52
52
  };
53
53
  shareButtonIcon: ReactNode;
54
54
  labelNode: ReactNode;
55
+ buttonClassName?: string;
55
56
  };
@@ -222,7 +222,8 @@ const CopyButtonWrapper = ({
222
222
  labelNode,
223
223
  url,
224
224
  ariaLabel,
225
- tooltipTexts
225
+ tooltipTexts,
226
+ buttonClassName
226
227
  }) => {
227
228
  const [tooltipText, setTooltipText] = React__default.useState("");
228
229
  const tooltipId = v4();
@@ -249,7 +250,8 @@ const CopyButtonWrapper = ({
249
250
  shareButtonStyles.root,
250
251
  shareButtonStyles.showTooltip,
251
252
  shareButtonStyles.container,
252
- "button"
253
+ "button",
254
+ buttonClassName
253
255
  );
254
256
  return /* @__PURE__ */ jsxs(Fragment, { children: [
255
257
  tooltipText && /* @__PURE__ */ jsx("div", { className, "aria-hidden": "true", children: /* @__PURE__ */ jsx(
@@ -311,6 +313,7 @@ const ShareButton = ({
311
313
  "label",
312
314
  (_b = elementProps == null ? void 0 : elementProps.label) == null ? void 0 : _b.className
313
315
  );
316
+ const buttonClassName = (_c = elementProps == null ? void 0 : elementProps.button) == null ? void 0 : _c.className;
314
317
  const platformIdWithFallback = getPlatformIdWithFallback(platformId, value);
315
318
  const translatedCopyLinkLabel = translations == null ? void 0 : translations[label2];
316
319
  const buttonLabel = platformIdWithFallback === platformIds.copyButton && translatedCopyLinkLabel ? translatedCopyLinkLabel : label2;
@@ -331,7 +334,8 @@ const ShareButton = ({
331
334
  svg: (illustration == null ? void 0 : illustration.svgId) ?? ""
332
335
  }
333
336
  ),
334
- labelNode: /* @__PURE__ */ jsx("span", { className: labelClassName, children: buttonLabel })
337
+ labelNode: /* @__PURE__ */ jsx("span", { className: labelClassName, children: buttonLabel }),
338
+ buttonClassName
335
339
  }
336
340
  ) : /* @__PURE__ */ jsxs(
337
341
  "a",
@@ -341,7 +345,7 @@ const ShareButton = ({
341
345
  shareButtonStyles.root,
342
346
  HAS_CUSTOM_FOCUS_CLASSNAME,
343
347
  "button",
344
- (_c = elementProps == null ? void 0 : elementProps.button) == null ? void 0 : _c.className
348
+ buttonClassName
345
349
  ),
346
350
  target: "popup",
347
351
  href: url,
@@ -98,10 +98,22 @@ export declare const DisplayNames: {
98
98
  };
99
99
  };
100
100
  export declare const DesignStates: {
101
- readonly root: {
101
+ readonly button: {
102
+ readonly hover: {
103
+ readonly displayName: "Hover";
104
+ readonly className: "share-buttons__button--hover";
105
+ };
106
+ };
107
+ readonly label: {
108
+ readonly hover: {
109
+ readonly displayName: "Hover";
110
+ readonly className: "share-buttons__label--hover";
111
+ };
112
+ };
113
+ readonly icon: {
102
114
  readonly hover: {
103
115
  readonly displayName: "Hover";
104
- readonly className: "share-buttons--hover";
116
+ readonly className: "share-buttons__icon--hover";
105
117
  };
106
118
  };
107
119
  };
@@ -87,7 +87,8 @@ button.root__jXw1V {
87
87
  }
88
88
 
89
89
  .root__jXw1V:hover .label__hsu2V,
90
- .share-buttons--hover .label__hsu2V {
90
+ .root__jXw1V.share-buttons__button--hover .label__hsu2V,
91
+ .label__hsu2V.share-buttons__label--hover {
91
92
  text-decoration: underline;
92
93
  }
93
94
 
@@ -1,4 +1,4 @@
1
- import { C as CSS_PROPERTIES, E as ELEMENTS, a as ACTIONS, D as DATA, N as NativeStateType, I as INTERACTIONS, L as LAYOUT, A as Archetype } from "../chunks/chunk-IO6HLVLV.js";
1
+ import { N as NativeStateType, C as CSS_PROPERTIES, E as ELEMENTS, a as ACTIONS, D as DATA, I as INTERACTIONS, L as LAYOUT, A as Archetype } from "../chunks/chunk-IO6HLVLV.js";
2
2
  import { h as DesignStates, i as DisplayNames, j as DisplayConfig, D as DefaultValues, I as IconPositionOptions, k as PageToShareOptions, m as DefaultButtons, B as ButtonWidthOptions } from "../chunks/constants22.js";
3
3
  import { c as manifestMouseHover } from "../chunks/manifestSdkMixins.js";
4
4
  import { w as withSpec } from "../chunks/manifest.js";
@@ -111,14 +111,6 @@ const manifest = {
111
111
  defaultValue: DefaultValues.buttonWidth
112
112
  }
113
113
  },
114
- states: {
115
- hover: withSpec({
116
- spec: IS_SUPPORT_DESIGN_STATE_SPEC,
117
- displayName: DesignStates.root.hover.displayName,
118
- className: DesignStates.root.hover.className,
119
- pseudoClass: NativeStateType.hover
120
- })
121
- },
122
114
  data: {
123
115
  buttons: {
124
116
  dataType: DATA.DATA_TYPE.arrayItems,
@@ -276,6 +268,14 @@ const manifest = {
276
268
  cssPropertyType: CSS_PROPERTIES.CSS_PROPERTY_TYPE.justifyContent,
277
269
  defaultValue: DefaultValues.contentAlignment
278
270
  }
271
+ },
272
+ states: {
273
+ hover: withSpec({
274
+ spec: IS_SUPPORT_DESIGN_STATE_SPEC,
275
+ displayName: DesignStates.button.hover.displayName,
276
+ className: DesignStates.button.hover.className,
277
+ pseudoClass: NativeStateType.hover
278
+ })
279
279
  }
280
280
  }
281
281
  },
@@ -298,8 +298,18 @@ const manifest = {
298
298
  letterSpacing: {
299
299
  defaultValue: "0em"
300
300
  },
301
- textDecorationLine: {},
301
+ textDecorationLine: {
302
+ statesDefaultValues: { hover: "underline" }
303
+ },
302
304
  textTransform: {}
305
+ },
306
+ states: {
307
+ hover: withSpec({
308
+ spec: IS_SUPPORT_DESIGN_STATE_SPEC,
309
+ displayName: DesignStates.label.hover.displayName,
310
+ className: DesignStates.label.hover.className,
311
+ pseudoClass: NativeStateType.hover
312
+ })
303
313
  }
304
314
  }
305
315
  },
@@ -326,6 +336,14 @@ const manifest = {
326
336
  "icon-rotation": {
327
337
  cssPropertyType: CSS_PROPERTIES.CSS_PROPERTY_TYPE.angle
328
338
  }
339
+ },
340
+ states: {
341
+ hover: withSpec({
342
+ spec: IS_SUPPORT_DESIGN_STATE_SPEC,
343
+ displayName: DesignStates.icon.hover.displayName,
344
+ className: DesignStates.icon.hover.className,
345
+ pseudoClass: NativeStateType.hover
346
+ })
329
347
  }
330
348
  }
331
349
  }
@@ -112,8 +112,14 @@ const DisplayNames = {
112
112
  }
113
113
  };
114
114
  const DesignStates = {
115
- root: {
116
- hover: { displayName: "Hover", className: "share-buttons--hover" }
115
+ button: {
116
+ hover: { displayName: "Hover", className: "share-buttons__button--hover" }
117
+ },
118
+ label: {
119
+ hover: { displayName: "Hover", className: "share-buttons__label--hover" }
120
+ },
121
+ icon: {
122
+ hover: { displayName: "Hover", className: "share-buttons__icon--hover" }
117
123
  }
118
124
  };
119
125
  const DefaultValues = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/editor-react-components",
3
- "version": "1.2548.0",
3
+ "version": "1.2550.0",
4
4
  "description": "React components for the Wix Editor",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -199,5 +199,5 @@
199
199
  "registry": "https://registry.npmjs.org/",
200
200
  "access": "public"
201
201
  },
202
- "falconPackageHash": "4fef7d863b9687b40deba4c86fb8bc19d12e656d76f78f1bc3169901"
202
+ "falconPackageHash": "6e3af4dd243bbcdda0c59e7f9834044167bf63a8333f4a99b1b05761"
203
203
  }