Giter Site home page Giter Site logo

Comments (6)

shinokada avatar shinokada commented on May 10, 2024 1

I just modified it for the svelte components.
You can see an example here.
Please update npm:

npm i -D flowbite-svelte@latest

Also please change your key name from title to name. After adding TS, I changed some of key names. Sorry.

interface InteractiveTabType {
    name: string;
    id: number;
    content: string | typeof SvelteComponent;
}

As you can see the content can hold either string or Svelte component.

from flowbite-svelte.

shinokada avatar shinokada commented on May 10, 2024 1

In the future version, the Interactive tab component change the structure. It will use slot so you can add another component or HTML etc. So it will be a BREAKING CHANGE.
The reason behind this change is to make the component more flexible. By using the slot, uses can add anything in the slot.

More details

from flowbite-svelte.

shinokada avatar shinokada commented on May 10, 2024 1

I leave the InteractiveTabs component as it is. And I just added InteractiveTabHead and TabContent components. It makes easy to add anything in the tab.
Demo

from flowbite-svelte.

shinokada avatar shinokada commented on May 10, 2024

Can I ask what kind of svelte component you are planning use? If you can give me an example, it will be helpful.

from flowbite-svelte.

Gildedter avatar Gildedter commented on May 10, 2024

I'm nesting this inside a modal, as a sort of per row menu.

i.e.
Table
->Rows
-->(column) Edit Button Modal
--->XL Modal
---->Interactive Tab as a tabbed menu of sorts
----->Individual Svelte Component Forms that hold menu items

from flowbite-svelte.

Gildedter avatar Gildedter commented on May 10, 2024

Thank you for the quick update, will update versions now. Haven't had any issues with the typings (new type props), its an easy update, thanks again for the library.

from flowbite-svelte.

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.