@digitalculture/ochre-sdk 0.12.8 → 0.12.9
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.
- package/dist/index.mjs +2 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2062,7 +2062,8 @@ function parseWebElementProperties(componentProperty, elementResource) {
|
|
|
2062
2062
|
}
|
|
2063
2063
|
case "search-bar": {
|
|
2064
2064
|
const boundElementPropertyUuid = getPropertyByLabel(componentProperty.properties, "bound-element")?.values[0]?.uuid;
|
|
2065
|
-
const
|
|
2065
|
+
const linkToProperty = getPropertyByLabel(componentProperty.properties, "link-to");
|
|
2066
|
+
const href = linkToProperty?.values[0]?.href ?? linkToProperty?.values[0]?.slug ?? null;
|
|
2066
2067
|
if (!boundElementPropertyUuid && !href) throw new Error(`Bound element or href not found for the following component: “${componentName}”`);
|
|
2067
2068
|
let variant = getPropertyValueByLabel(componentProperty.properties, "variant");
|
|
2068
2069
|
variant ??= "default";
|
package/package.json
CHANGED