smoothly 0.1.83 → 0.1.84

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -40,22 +40,14 @@ let Calendar = class {
40
40
  event.stopPropagation();
41
41
  } }),
42
42
  h("table", null, h("thead", null, h("tr", null, weekdays().map(day => (h("th", null, day))))), month((_b = this.month) !== null && _b !== void 0 ? _b : this.value).map(week => (h("tr", null, week.map(date => {
43
- var _a, _b, _c, _d, _e, _f, _g;
44
- return (h("td", { tabindex: 1, onClick: this.min || this.max
45
- ? !(date < ((_a = this.min) !== null && _a !== void 0 ? _a : "") || date > ((_b = this.max) !== null && _b !== void 0 ? _b : ""))
46
- ? () => this.onClick(date)
47
- : undefined
48
- : () => this.onClick(date), class: (date == this.value ? ["selected"] : [])
49
- .concat(...(date == dist.Date.now() ? ["today"] : []), dist.Date.firstOfMonth((_c = this.month) !== null && _c !== void 0 ? _c : this.value) == dist.Date.firstOfMonth(date) ? ["currentMonth"] : [], this.doubleInput
50
- ? date >= ((_d = this.start) !== null && _d !== void 0 ? _d : "") && date <= ((_e = this.end) !== null && _e !== void 0 ? _e : "")
43
+ var _a, _b, _c;
44
+ return (h("td", { tabindex: 1, onClick: (this.min || this.max) && (date < this.min || date > this.max) ? undefined : () => this.onClick(date), class: (date == this.value ? ["selected"] : [])
45
+ .concat(...(date == dist.Date.now() ? ["today"] : []), dist.Date.firstOfMonth((_a = this.month) !== null && _a !== void 0 ? _a : this.value) == dist.Date.firstOfMonth(date) ? ["currentMonth"] : [], this.doubleInput
46
+ ? date >= ((_b = this.start) !== null && _b !== void 0 ? _b : "") && date <= ((_c = this.end) !== null && _c !== void 0 ? _c : "")
51
47
  ? ["dateRange"]
52
48
  : []
53
49
  : "")
54
- .concat(...(this.min || this.max
55
- ? date < ((_f = this.min) !== null && _f !== void 0 ? _f : "") || date > ((_g = this.max) !== null && _g !== void 0 ? _g : "")
56
- ? ["disable"]
57
- : []
58
- : ""))
50
+ .concat(...(this.min || this.max ? (date < this.min || date > this.max ? ["disable"] : []) : ""))
59
51
  .join(" ") }, date.substring(8, 10)));
60
52
  }))))),
61
53
  ];
@@ -6,8 +6,8 @@ export declare class Calendar {
6
6
  value: Date;
7
7
  start?: Date;
8
8
  end?: Date;
9
- max?: Date;
10
- min?: Date;
9
+ max: Date;
10
+ min: Date;
11
11
  doubleInput: boolean;
12
12
  valueChanged: EventEmitter<Date>;
13
13
  startChanged: EventEmitter<Date>;
@@ -26,8 +26,8 @@ export namespace Components {
26
26
  interface SmoothlyCalendar {
27
27
  "doubleInput": boolean;
28
28
  "end"?: Date;
29
- "max"?: Date;
30
- "min"?: Date;
29
+ "max": Date;
30
+ "min": Date;
31
31
  "month"?: Date;
32
32
  "start"?: Date;
33
33
  "value": Date;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "smoothly",
3
- "version": "0.1.83",
3
+ "version": "0.1.84",
4
4
  "description": "Web component library written in Stencil.",
5
5
  "author": "PayFunc",
6
6
  "license": "MIT",