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 🙏

© 2024 – Pkg Stats / Ryan Hefner

@aurelia-toolkit/mdc-datepicker

v3.0.8

Published

Aurelia Toolkit MDC Datepicker

Downloads

2,134

Readme

Aurelia MDC Datepicker

npm version

Installation

npm @aurelia-toolkit/mdc-datepicker date-fns inputmask @aurelia-toolkit/mdc-inputmask --save

If only the dialog is used inputmask and @aurelia-toolkit/mdc-inputmask may be ommited. You will get peer dependency warnings which can be ignored.

Configuration

// main.ts
export function configure(aurelia: Aurelia) {
    aurelia.use.plugin(PLATFORM.moduleName('@aurelia-toolkit/mdc-datepicker'), (c: MdcDatepickerDialogConfiguration) => {
      // the dialog is localised via default options
      c.defaultOptions.i18n.dateFnsLocale = enAU;
      c.defaultOptions.firstDay = 1;
    });
    // the rest of your configuration...
}
// main.scss
@use "@aurelia-toolkit/mdc-datepicker";

Usage

<mdc-datepicker value.bind="date" format="dd/MM/yyyy" inputmask-format="dd/mm/yyyy"></mdc-datepicker>
<!-- format attribute accepts date-fns format tokens  -->
<!-- inputmask-format attribute accepts inputmask format tokens  -->

mdc-datepicker custom element uses inputmask to limit user's input. You can use the datepicker dialog separately via the MDC dialog service

const dialogService: MdcDialogService;
const data: Partial<IMdcDatepickerDialogData> = {
  date: this.getDateValue(),
  options: {
    label: 'Select Date'
  }
};
const result = await dialogService.open({ viewModel: MdcDatepickerDialog, model: data });
if (result === 'ok') {
  console.log(data.date);
}

Contribution

If you feel that something is missing please submit an issue or better yet a PR.