3.0.4 • Published 15 days ago

@studyportals/monthpicker v3.0.4

Weekly downloads
-
License
BSD-3
Repository
github
Last release
15 days ago

Monthpicker

Studyportals Monthpicker is a Monthpicker input component to be used in Vue.js.

Table of Contents

Setup & commands

The following commands can be used to setup and build the package. Also, we're using jest to run unit tests before a git push is done. This could be by-passed (if absolutely necessary) by running git push --no-verify.

# install dependencies
npm install

# publish the package to npm
npm publish --public true

# build the package for local testing
npm run build

# run linter
npm run lint
npm run lint:fix # with fix

# run unit tests
npm run unit

Including Monthpicker in your project

Monthpicker is a DLL supported component. This means that you should install it's DLL package and then reference the DLL in the build setup of the project that is integrating it.

npm install @studyportals/monthpicker-dll
dllPackages: [
	{
		name: "monthpicker-dll",
		manifest: require("@studyportals/monthpicker-dll/dist/monthpicker.json")
	}
]

When running your project outside of a portal environment you will need to include the monthpicker-dll bundle from our CDN:

<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/@studyportals/monthpicker-dll@version/dist/monthpicker.min.js"></script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@studyportals/monthpicker-dll@version/dist/monthpicker.min.css">

Then you will be able to import Monthpicker in your component files:

import { Monthpicker } from "@studyportals/monthpicker";

And import Monthpicker styling in your component files:

@import '~@studyportals/monthpicker/dist/style.css';

Properties

Monthpicker has a properties that can be configured to control behaviour.


allowPastDates : boolean

Default value: false


label : string

Default value:


defaultMonth : string

Default value:

The month value that will be pre-populated in the control.


defaultYear : string

Default value:

The year value that will be pre-populated in the control.


pastYearsRange : number

The maximum number of past years, from the current year, to be included as valid options.


futureYearsRange : number

The maximum number of future years, from the current year, to be included as valid options.


Events

The Monthpicker component emits the following events:

dateSelected : {year: string, month: string}

dateSelected is emitted when the users selects a valid date, either through text input or through the month select. This event will only be emitted once the user's selection passes validation (both regarding syntax and whether past dates are allowed). Returns an object with a year and month value as strings.

3.0.4-1

15 days ago

3.0.4-0

15 days ago

3.0.4

5 months ago

3.0.3

5 months ago

3.0.2

5 months ago

3.0.1

8 months ago

3.0.1-0

8 months ago

3.0.0

1 year ago

3.0.0-7

1 year ago

3.0.0-6

1 year ago

3.0.0-1

1 year ago

3.0.0-0

1 year ago

3.0.0-3

1 year ago

3.0.0-2

1 year ago

3.0.0-5

1 year ago

3.0.0-4

1 year ago

2.2.3

1 year ago

2.2.4

1 year ago

2.2.3-1

1 year ago

2.2.3-0

1 year ago

2.2.0-beta.0

2 years ago

2.2.0-beta.1

2 years ago

2.0.3-beta.1

2 years ago

2.2.1

2 years ago

2.0.3

2 years ago

2.2.0

2 years ago

2.2.2

1 year ago

2.2.1-1

2 years ago

2.2.1-0

2 years ago

2.2.2-4

1 year ago

2.2.2-3

1 year ago

2.2.2-2

1 year ago

2.2.2-1

1 year ago

2.2.2-0

1 year ago

2.3.0-0

2 years ago

1.0.2

2 years ago

2.0.3-beta.0

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

2.0.2

2 years ago

2.1.0-1

2 years ago

2.1.0-0

2 years ago

2.1.0-2

2 years ago

2.0.1

2 years ago

2.0.0

2 years ago

2.0.0-beta.7

2 years ago

2.1.1

2 years ago

2.0.0-beta.2

2 years ago

2.0.0-beta.1

2 years ago

2.0.0-beta.0

2 years ago

2.0.0-beta.6

2 years ago

2.1.0

2 years ago

2.0.0-beta.4

2 years ago

2.0.0-beta.3

2 years ago

1.0.4-beta.0

2 years ago

1.0.3-beta.0

2 years ago

1.0.4-beta.1

2 years ago

1.0.4-beta.2

2 years ago

1.0.4-beta.3

2 years ago

1.0.4-beta.4

2 years ago

1.0.2-beta.0

2 years ago

1.0.4-beta.5

2 years ago

1.0.2-beta.1

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago

0.0.1-beta.32

2 years ago

0.0.1-beta.29

2 years ago

0.0.1-beta.28

2 years ago

0.0.1-beta.25

2 years ago

0.0.1-beta.24

2 years ago

0.0.1-beta.27

2 years ago

0.0.1-beta.26

2 years ago

0.0.1-beta.31

2 years ago

0.0.1-beta.30

2 years ago

0.0.1-beta.23

2 years ago

0.0.1-beta.22

2 years ago

0.0.1-beta.21

2 years ago

0.0.1-beta.20

2 years ago

0.0.1-beta.19

2 years ago

0.0.1-beta.17

2 years ago

0.0.1-beta.16

2 years ago

0.0.1-beta.15

2 years ago

0.0.1-beta.14

2 years ago

0.0.1-beta.13

2 years ago

0.0.1-beta.12

2 years ago

0.0.1-beta.11

2 years ago

0.0.1-beta.10

2 years ago

0.0.1-beta.9

2 years ago

0.0.1-beta.8

2 years ago

0.0.1-beta.7

2 years ago

0.0.1-beta.6

2 years ago

0.0.1-beta.4

2 years ago

0.0.1-beta.3

2 years ago

0.0.1-beta.2

2 years ago

0.0.1-beta.1

2 years ago