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

mds.angular.datetimepicker

v3.1.8

Published

Persian and gregorian DateTimePicker with angular and materials

Downloads

70

Readme

Mds Angular Persian and Gregorian DateTimePicker

Persian and gregorian DateTimePicker with angular 4 and angular materials

Installing package via npm:

npm install mds.angular.datetimepicker@latest

Also, you need to install mds.persian.datetime via npm:

npm install mds.persian.datetime@latest

Demo


Mds Angular Persian and Gregorian DateTimePicker Mds Angular Persian and Gregorian DateTimePicker


How To Use:

  1. First add import to your module,
import { MdsAngularPersianDateTimePickerModule } from 'mds.angular.datetimepicker';

@NgModule({
  declarations: [AppComponent],
  imports: [BrowserModule, MdsAngularPersianDateTimePickerModule],
  providers: [], 
  bootstrap: [AppComponent]
})
export class AppModule { }
  1. Install Requirements: You can install these packages as follows:
npm install mds.persian.datetime
npm install --save @angular/material @angular/cdk
npm install --save @angular/animations
npm install jquery
npm install popper.js
npm install bootstrap

Guidance You can add bootstrap and jquery to your angular 6 project as follows: Open angular.json add these lines

 "styles": [
    "node_modules/@angular/material/prebuilt-themes/indigo-pink.css",
    "node_modules/bootstrap/dist/css/bootstrap.min.css",
    "src/styles.css"
  ],
  "scripts": [
    "node_modules/jquery/dist/jquery.min.js",
    "node_modules/popper.js/dist/umd/popper.min.js",
    "node_modules/bootstrap/dist/js/bootstrap.min.js"
  ]
  1. Add to view:
    <mds-angular-persian-datetimepicker      
      [inLine]="false" [placeHolder]="'Mds DateTime Picker'"> 
    </mds-angular-persian-datetimepicker>

Options

| Name | Type | Values | Description | --------------|----------------|-------------------|--------------| initialValue | string | | Initial value of datetime Picker You can initial date time picker with it. Example: 1396/06/06 or 1396/05/06 10:20:00 for persian 2017/06/06 or 2017-06-06 10:20 for gregorian isPersian | boolean | true, [false] | Is date time picker persian or gregorian timePicker | boolean | true, [false] | Is time picker enable templateType | Enumeration | 1, [2] | You can choose how your date time picker generateIn materials you have animations 1 = bootstrap 2 = material inLine | boolean | false, [true] | Show date time picker as in line in page textBoxType | Enumeration | 1, [2] | If you choose [inLine]="false" it shows a textbox as pickerYou can choose how should it shows 1 = withButton 2 = withoutButton placeHolder | string | | Place holder of text box buttonIcon | string | | Icon of datepicker buttonSample: <span class="fa fa-calendar" aria-hidden="true"></span> Default is 📅 rangeSelector | boolean | false, [true] | Is date picker range selector format | string | format string | Format of showing date time فرمت پیش فرض 1393/09/14 13:49:40 yyyy: سال چهار رقمی yy: سال دو رقمی MMMM: نام فارسی ماه MM: عدد دو رقمی ماه M: عدد یک رقمی ماه dddd: نام فارسی روز هفته dd: عدد دو رقمی روز ماه d: عدد یک رقمی روز ماه HH: ساعت دو رقمی با فرمت 00 تا 24 H: ساعت یک رقمی با فرمت 0 تا 24 hh: ساعت دو رقمی با فرمت 00 تا 12 h: ساعت یک رقمی با فرمت 0 تا 12 mm: عدد دو رقمی دقیقه m: عدد یک رقمی دقیقه ss: ثانیه دو رقمی s: ثانیه یک رقمی fff: میلی ثانیه 3 رقمی ff: میلی ثانیه 2 رقمی f: میلی ثانیه یک رقمی tt: ب.ظ یا ق.ظ t: حرف اول از ب.ظ یا ق.ظ


Events

| Name | Description | --------------|--------------| dateChanged(date: IMdsAngularDateTimePickerDate) | Occurs whenever selected date change rangeDateChanged(rangeDate: IMdsAngularDateTimePickerRangeDate) | Occurs whenever selected range date change keyDown(event: IEventModel) | Occurs whenever keydown event fires on datepicker text box blur(event: IEventModel) | Occurs whenever blur event fires on datepicker text box focus(event: IEventModel) | Occurs whenever focus event fires on datepicker text box

Sample

<mds-datetime-picker (dateChanged)="mdsDatePicker2OnDateChange($event)" (rangeDateChanged)="mdsDatePicker1OnDateRangeChange($event)"  [isPersian]="false" [templateType]="1" [rangeSelector]="true">
</mds-datetime-picker>

https://github.com/Mds92/Mds92.github.io/tree/master/MdsDateTimePickerSample