@rakuten-rex/date-picker
Advanced tools
Comparing version 1.0.0 to 1.0.1
/* | ||
@license @rakuten-rex/date-picker v1.0.0 2020-01-10 | ||
@license @rakuten-rex/date-picker v1.0.1 2020-01-10 | ||
DatePicker/DatePicker.production.min.js | ||
@@ -68,4 +68,4 @@ | ||
Ra(Object(c),!0).forEach(function(b){Qa()(a,b,c[b])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(c)):Ra(Object(c)).forEach(function(b){Object.defineProperty(a,b,Object.getOwnPropertyDescriptor(c,b))})}return a}function va(a){a=a.numberOfMonths;var b=Object(w.useState)({startDate:null,endDate:null,focusedInput:"startDate"});b=wa()(b,2);var c=b[0],d=b[1],e=Ka({startDate:c.startDate,endDate:c.endDate,focusedInput:c.focusedInput,onDatesChange:function(a){a.focusedInput? | ||
d(a):d(zb({focusedInput:"startDate"},a))},numberOfMonths:a,firstDayOfWeek:0}),l=e.firstDayOfWeek;a=e.activeMonths;b=e.isDateSelected;var g=e.isDateHovered,h=e.isFirstOrLastSelectedDate,m=e.isDateBlocked,k=e.isDateFocused,n=e.focusedDate,q=e.onDateHover,p=e.onDateSelect,u=e.onDateFocus,v=e.goToPreviousMonths;e=e.goToNextMonths;Object(w.useEffect)(function(){var a=document.querySelectorAll(".rex-datePicker-month"),b=a[0].offsetWidth,c=document.querySelector(".rex-datePicker-wrapper");a=2>a.length?"".concat(b): | ||
a.length*b+16*(a.length-1);c.style.width="".concat(a,"px")});return r(ua.Provider,{value:{focusedDate:n,isDateFocused:k,isDateSelected:b,isDateHovered:g,isDateBlocked:m,isFirstOrLastSelectedDate:h,onDateSelect:p,onDateFocus:u,onDateHover:q}},r("div",{css:{fontFamily:"Noto Sans CJK JP"}},r("strong",null,"Focused input: "),c.focusedInput),r("div",{css:{fontFamily:"Noto Sans CJK JP"}},r("strong",null,"Start date: "),c.startDate&&c.startDate.toLocaleString()),r("div",{css:{fontFamily:"Noto Sans CJK JP"}}, | ||
d(a):d(zb({},a,{focusedInput:"startDate"}))},numberOfMonths:a,firstDayOfWeek:0}),l=e.firstDayOfWeek;a=e.activeMonths;b=e.isDateSelected;var g=e.isDateHovered,h=e.isFirstOrLastSelectedDate,m=e.isDateBlocked,k=e.isDateFocused,n=e.focusedDate,q=e.onDateHover,p=e.onDateSelect,u=e.onDateFocus,v=e.goToPreviousMonths;e=e.goToNextMonths;Object(w.useEffect)(function(){var a=document.querySelectorAll(".rex-datePicker-month"),b=a[0].offsetWidth,c=document.querySelector(".rex-datePicker-wrapper");a=2>a.length? | ||
"".concat(b):a.length*b+16*(a.length-1);c.style.width="".concat(a,"px")});return r(ua.Provider,{value:{focusedDate:n,isDateFocused:k,isDateSelected:b,isDateHovered:g,isDateBlocked:m,isFirstOrLastSelectedDate:h,onDateSelect:p,onDateFocus:u,onDateHover:q}},r("div",{css:{fontFamily:"Noto Sans CJK JP"}},r("strong",null,"Focused input: "),c.focusedInput),r("div",{css:{fontFamily:"Noto Sans CJK JP"}},r("strong",null,"Start date: "),c.startDate&&c.startDate.toLocaleString()),r("div",{css:{fontFamily:"Noto Sans CJK JP"}}, | ||
r("strong",null,"End date: "),c.endDate&&c.endDate.toLocaleString()),r("div",{className:"rex-datePicker-wrapper",css:{display:"grid",margin:"32px 0 0",gridTemplateColumns:"repeat(".concat(a.length,", 328px)"),gridGap:"0 16px",position:"relative"}},r(D,{onClick:v,pos:"left"}),r(D,{onClick:e,pos:"right"}),a.map(function(a){return r(la,{key:"".concat(a.year,"-").concat(a.month),year:a.year,month:a.month,firstDayOfWeek:l,startDate:c.startDate,endDate:c.endDate})})))}function Sa(){var a=Object(w.useState)(null); | ||
@@ -72,0 +72,0 @@ a=wa()(a,2);var b=a[0],c=a[1];a=Object(w.useState)(null);a=wa()(a,2);var d=a[0],e=a[1],l=Ka({startDate:b,endDate:d,focusedInput:"startDate",onDatesChange:function(a){c(a.startDate);e(a.startDate)},numberOfMonths:1,firstDayOfWeek:0}),g=l.firstDayOfWeek;a=l.activeMonths;var h=l.isDateSelected,m=l.isDateHovered,k=l.isFirstOrLastSelectedDate,n=l.isDateBlocked,q=l.isDateFocused,p=l.focusedDate,u=l.onDateHover,v=l.onDateSelect,x=l.onDateFocus,G=l.goToPreviousMonths;l=l.goToNextMonths;Object(w.useEffect)(function(){var a= |
{ | ||
"name": "@rakuten-rex/date-picker", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -12,3 +12,3 @@ # ReX React UI Component: date-picker | ||
``` | ||
npm install @rakuten-rex/date-picker@1.0.0 --save | ||
npm install @rakuten-rex/date-picker@1.0.1 --save | ||
``` | ||
@@ -19,3 +19,3 @@ | ||
``` | ||
yarn add @rakuten-rex/date-picker@1.0.0 | ||
yarn add @rakuten-rex/date-picker@1.0.1 | ||
``` | ||
@@ -287,3 +287,3 @@ | ||
``` | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.0/MyComponent/MyComponent.production.min.css | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.1/MyComponent/MyComponent.production.min.css | ||
``` | ||
@@ -295,3 +295,3 @@ | ||
``` | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.0/MyComponent/MyComponent.development.css | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.1/MyComponent/MyComponent.development.css | ||
``` | ||
@@ -303,3 +303,3 @@ | ||
``` | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.0/MyComponent/MyComponent.static.css | ||
https://unpkg.com/@rakuten-rex/date-picker@1.0.1/MyComponent/MyComponent.static.css | ||
``` | ||
@@ -321,3 +321,3 @@ | ||
<!-- ReX date-picker --> | ||
<link href="https://unpkg.com/@rakuten-rex/date-picker@1.0.0/MyComponent/MyComponent.production.min.css" rel="stylesheet"> | ||
<link href="https://unpkg.com/@rakuten-rex/date-picker@1.0.1/MyComponent/MyComponent.production.min.css" rel="stylesheet"> | ||
</head> | ||
@@ -324,0 +324,0 @@ <body> |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1643058