npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

anq-modal-form

v0.0.20

Published

A powerful, customizable modal form component for Quasar Framework and Vue 3 applications. Features include responsive design, dynamic form generation, validation, animations, and seamless integration with Quasar's design system.

Readme

ANQ Modal Form

A powerful, customizable modal form component for Quasar Framework and Vue 3 applications. This component provides a seamless way to handle forms within modals, featuring dynamic form generation, validation, and smooth animations.

Features

  • 🎯 Dynamic form generation
  • ✅ Built-in form validation
  • 🎨 Seamless Quasar UI integration
  • 📱 Responsive design
  • ⚡ Vue 3 Composition API support
  • 🔒 TypeScript support
  • 🎭 Customizable animations
  • 🎨 Theme support
  • 🔄 Form state management
  • 📦 Easy to integrate

Installation

# Using npm
npm install anq-modal-form

# Using yarn
yarn add anq-modal-form

# Using pnpm
pnpm add anq-modal-form

Quick Start

<template>
  <div>
    <q-btn 
      label="Open Form" 
      color="primary" 
      @click="modalRef?.show()" 
    />
    
    <AnqModalForm
      ref="modalRef"
      title="Form Title"
      @submit="onSubmit"
      @hide="onModalHide"
    >
      <template #content>
        <div class="q-pa-md">
          <q-form @submit="onSubmit" class="q-gutter-md">
            <q-input
              v-model="formData.field1"
              label="Field 1"
              :rules="[val => !!val || 'Field is required']"
              outlined
            />
            <!-- Add more form fields as needed -->
          </q-form>
        </div>
      </template>
    </AnqModalForm>
  </div>
</template>

<script setup lang="ts">
import { ref, reactive } from 'vue';
import { AnqModalForm } from 'anq-modal-form';

const modalRef = ref<InstanceType<typeof AnqModalForm> | null>(null);

const formData = reactive({
  field1: ''
});

const onSubmit = () => {
  console.log('Form submitted:', formData);
  modalRef.value?.hide();
};

const onModalHide = () => {
  console.log('Modal hidden');
};
</script>

Props

| Prop | Type | Default | Description | |------|------|---------|-------------| | isLoading | Boolean | false | Shows loading state on the submit button | | formIsLoading | Boolean | false | Shows loading state on the form | | okLabel | String | 'Ok' | Label for the submit button | | cancelLabel | String | 'Cancel' | Label for the cancel button | | title | String | 'Title' | Modal title | | btnsColor | QBtnProps['color'] | 'primary' | Color for the buttons | | modalCardProps | { class?: string; style?: string } & QCard['$props'] | undefined | Additional props for the q-card component |

Events

| Event | Parameters | Description | |-------|------------|-------------| | submit | () | Emitted when form is submitted | | hide | () | Emitted when modal is hidden |

Slots

| Slot | Props | Description | |------|-------|-------------| | content | - | Main content of the modal | | close-icon-btn | color, disable | Custom close button | | cancel-btn | color, disable, label | Custom cancel button | | ok-btn | color, label, disable, loading | Custom submit button |

Examples

Basic Form with Validation

<template>
  <AnqModalForm
    ref="modalRef"
    title="User Registration"
    @submit="onSubmit"
  >
    <template #content>
      <div class="q-pa-md">
        <q-form @submit="onSubmit" class="q-gutter-md">
          <q-input
            v-model="formData.email"
            label="Email"
            type="email"
            :rules="[
              val => !!val || 'Email is required',
              val => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(val) || 'Invalid email format'
            ]"
            outlined
          />
        </q-form>
      </div>
    </template>
  </AnqModalForm>
</template>

Form with Custom Buttons

<template>
  <AnqModalForm
    ref="modalRef"
    title="Custom Form"
    @submit="onSubmit"
  >
    <template #ok-btn="{ color, label, disable, loading }">
      <q-btn
        :color="color"
        :label="label"
        :disable="disable"
        :loading="loading"
        icon="check"
      />
    </template>
  </AnqModalForm>
</template>

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Support

If you find this project helpful, please give it a ⭐️ on GitHub!