0.1.2 • Published 4 years ago

asmmodal v0.1.2

Weekly downloads
3
License
MIT
Repository
-
Last release
4 years ago

asmmodal

The asmmodal component is a customizable component.

Example

  • Clone the project
  • npm install
  • npm run dev
  • Open browser to local server

Usage

NPM

npm install asmmodal --save-dev

Bootstrap

bootstrap@4.5.0

Vue

Vue.use

....
import AsmModal from 'asmmodal';
import 'asmmodal/dist/asm.css';
Vue.use(AsmModal);
....
/*
    <AsmModal
        :modal-show="false"
        @closeModal="onCloseModal"
    >
    </AsmModal>
*/
....

import {AsmModal}

....
import { AsmModal } from 'asmmodal';
import 'asmmodal/dist/asm.css';
....
components:{
    ....
    'asm-modal':AsmModal
}
....

Documentation

Available Props

PropTypeDefaultDescriptionRequired
modal-showBooleanfalseModal State (show/close)True
modal-infoObjectModal Title, Modal contents
modal-sizeString''Modal Sizes (sm,lg,xl)
modal-centeredBooleanfalseModal Vertical alignment
modal-scrollableBooleanfalseWith or without modal scrolling
modal-stackingBooleanfalseModal stacking state
modal-headerBooleantrueModal header state
modal-footerBooleantrueModal footer state
modal-idString''Modal id value
modal-header-classString''Modal header class value
modal-footer-classString''Modal footer class value
modal-classString''Modal theme class value
modal-btnString'primary'Modal theme button class value
modal-lazyBooleanfalseModal lazy state
modal-back-dropBooleanfalseModal background state

Available Events

MethodTypeDefaultDescriptionRequired
closeModalfunctionModal close actionTrue
activeEventOkfunctionModal 'confirm' action
activeEventClosefunctionModal close action

Browser Support

  • chrome
  • ie 10+
  • safari
  • firefox
  • opera

License

AsmModal is open source and released under the MIT License.