Giter VIP home page Giter VIP logo

Comments (3)

MilanFox avatar MilanFox commented on August 17, 2024 1

Hey thanks! Fully understandable - This would be much appreciated, but in the meantime, we are using a workaround through the Management API, so we are not in a hurry right now.

from field-plugin.

MilanFox avatar MilanFox commented on August 17, 2024

I have decided to quickly set up a minimal repro anyways, just for convenience:

This Field Type Plugin:

<template>
  <SbButton size="small" @click="handleSelectAsset" is-full-width>Select Asset</SbButton>
  <SbButton size="small" @click="removeAsset" is-full-width>RemoveAsset</SbButton>
  <pre>{{ asset }}</pre>
</template>

<script setup lang="ts">
import { useFieldPlugin } from '@storyblok/field-plugin/vue3'
import { SbButton } from '@storyblok/design-system'
import { ref } from 'vue'

import type { Asset } from '@storyblok/field-plugin'

const asset = ref<Asset>()

const plugin = useFieldPlugin()

const handleSelectAsset = async () => {
  asset.value = await plugin?.actions?.selectAsset()
}

const removeAsset = () => {
  asset.value = undefined
}
</script>

produces this example output after selecting an image asset (I just printed it below the two buttons, sorry for the horrible formating)

Bildschirmfoto 2024-06-24 um 18 13 54

Selecting the same image with the native Asset Picker gives me all of these and not just the filename:

Bildschirmfoto 2024-06-24 um 18 17 53

from field-plugin.

eunjae-lee avatar eunjae-lee commented on August 17, 2024

Hi @MilanFox thanks for suggesting this change 🙂
As we are in the middle of something, I cannot guarantee the ETA, but I will hopefully discuss about this and bring it to you soon.

from field-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.