@bigbinary/neeto-molecules 5.3.13 → 5.3.15

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.
@@ -3,21 +3,21 @@ import { useEffect, useState, useMemo, useRef, createElement } from 'react';
3
3
  import { isPresent, filterBy, hyphenate, noop } from '@bigbinary/neeto-cist';
4
4
  import { useLocation, useHistory } from 'react-router-dom';
5
5
  import _defineProperty from '@babel/runtime/helpers/defineProperty';
6
- import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
6
+ import { t } from 'i18next';
7
7
  import { Label, Input, Button, Select, ColorPicker, Checkbox, Switch, Typography, Spinner, Callout } from '@bigbinary/neeto-atoms';
8
- import classnames from 'classnames';
9
- import { toPairs, mergeDeepLeft, isEmpty, mergeLeft } from 'ramda';
10
8
  import { useTranslation } from 'react-i18next';
11
- import { t } from 'i18next';
12
9
  import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
13
10
  import HelpPopover from './HelpPopover.js';
14
11
  import { withImmutableActions, handleMetaClick } from '@bigbinary/neeto-commons-frontend/v2/react-utils';
15
12
  import { create } from 'zustand';
13
+ import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
16
14
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
15
+ import { toPairs, mergeDeepLeft, isEmpty, mergeLeft } from 'ramda';
17
16
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
18
17
  import { T as Trash2 } from '../trash-2-hGkzsa87.js';
19
18
  import { P as Plus } from '../plus-Bnd2C3yl.js';
20
19
  import _objectDestructuringEmpty from '@babel/runtime/helpers/objectDestructuringEmpty';
20
+ import classnames from 'classnames';
21
21
  import Codeblock from './Codeblock.js';
22
22
  import { globalProps as globalProps$1 } from '@bigbinary/neeto-commons-frontend/v2/initializers';
23
23
  import BrowserPreview from './BrowserPreview.js';
@@ -1854,7 +1854,8 @@ var ProductEmbed = function ProductEmbed(_ref) {
1854
1854
  var _useLocation = useLocation(),
1855
1855
  search = _useLocation.search;
1856
1856
  var queryParams = new URLSearchParams(search);
1857
- var selectedEmbed = toCamelCasedString(queryParams.get("type"));
1857
+ var typeFromQueryParams = toCamelCasedString(queryParams.get("type"));
1858
+ var selectedEmbed = Object.values(EMBED_OPTIONS).includes(typeFromQueryParams) && Object.keys(options).includes(typeFromQueryParams) ? typeFromQueryParams : undefined;
1858
1859
  var _useProductEmbedStore = useProductEmbedStore(useShallow(function (store) {
1859
1860
  return {
1860
1861
  setProductEmbedState: store["setProductEmbedState"]