Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(picker-starter): update the field plugin to the latest version #98

Merged
merged 2 commits into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion picker-starter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
},
"dependencies": {
"@storyblok/design-system": "3.19.3",
"@storyblok/field-plugin": "1.0.0",
"@storyblok/field-plugin": "^1.4.0",
"debounce": "^1.2.1",
"vue": "^3.2.47",
"vue-draggable-next": "^2.2.1"
Expand Down
6 changes: 3 additions & 3 deletions picker-starter/src/components/FieldPlugin.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,19 @@ import setup from '../picker.config'
const plugin = useFieldPlugin()

const content = computed(() => {
const content = plugin.data.content
const content = plugin.data?.content
return typeof content === 'object' ? content : { name: pluginName }
})

const setValue = (content: any) => {
plugin.actions.setContent({
plugin.actions?.setContent({
plugin: pluginName,
...content,
})
}

const servicePluginParams = computed(() => {
return setup(plugin.data.options)
return setup(plugin.data?.options || {})
})
</script>

Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1416,10 +1416,10 @@
resolved "https://registry.yarnpkg.com/@storyblok/field-plugin/-/field-plugin-0.0.1-beta.2.tgz#b2f2640912e42fa740ffb480ccaefd46eaad2182"
integrity sha512-MwxLJnE9nNvTiw5xWKdh53buAKWIrHbUW+fwyz18C3jY2fZR7WL6m0p3Wgxx2ASKb7gfQXuHt3JjZXwWjXNOYQ==

"@storyblok/field-plugin@1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@storyblok/field-plugin/-/field-plugin-1.0.0.tgz#6fafcc5e55f83fc1dd8402d192f38e2031c0ea9a"
integrity sha512-g7do7KqCP8LYLMCnQSAwSLgP0i0xjzifity23BmZrmVda1jIy4p+CwFsIeFIDZ/OYt13SICHhawf6tfUeWiVrg==
"@storyblok/field-plugin@^1.4.0":
version "1.4.1"
resolved "https://registry.yarnpkg.com/@storyblok/field-plugin/-/field-plugin-1.4.1.tgz#032c33024101b1583610d8a41f5a3fcbfaaa538a"
integrity sha512-q4LMhtoBdSivv8NrRFhMhp3+SmN2VpFbz8RHcLzcWxhZ0JX3l/CFEFuiWilrUt1cHQvasj5IhFMRvnD+1ym0jg==

"@storyblok/mui@^0.2.0":
version "0.2.0"
Expand Down
Loading