1.0.3 â€Ē Published 6 months ago

@simularge/card v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
6 months ago

Simularge Card

A lightweight, customizable card component built with vanilla JavaScript using Web Components. No framework dependencies required!

Features

  • ðŸŽĻ Quasar styling
  • 📝 Custom text/subtitle/content/image/separator
  • ðŸŽŊ Framework agnostic
  • ðŸŠķ Lightweight with zero dependencies
  • 🎭 Shadow DOM for style encapsulation

Installation

npm install @simularge/card

Usage

  1. Import the component in your JavaScript file:
import '@simularge/card';
  1. Use the component in your HTML:
<!-- Card with image -->
<simularge-card
    title="Our Changing Planet"
    subtitle="by John Doe"
    content="Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."
    image="https://cdn.quasar.dev/img/mountains.jpg"
></simularge-card>

<!-- Card with separator -->
<simularge-card
    title="Welcome to Simularge"
    subtitle="Featured Article"
    content="This is a custom card showcasing the text-only layout. It still looks great without an image!"
    separator
></simularge-card>

Props

PropTypeDefaultDescription
titlestring"Button"The text to display on button
subtitlestring""The text to display on button
contentstring""The text to display on button
imagestring""The text to display on button
separatorbooleanfalseThe text to display on button

Styling

The card uses Shadow DOM for style encapsulation, ensuring that your application styles don't interfere with the card's appearance. The component comes with built-in styles including:

  • Hover and active states
  • Smooth transitions
  • Modern, clean design

Browser Support

Works in all modern browsers that support Web Components:

  • Chrome
  • Firefox
  • Safari
  • Edge

License

MIT

1.0.3

6 months ago

1.0.2

6 months ago

1.0.1

6 months ago

1.0.0

6 months ago