Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rc-picker

Package Overview
Dependencies
Maintainers
1
Versions
313
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rc-picker - npm Package Compare versions

Comparing version 0.0.1-alpha.14 to 0.0.1-alpha.15

27

es/PickerPanel.js
"use strict";
/* eslint-disable jsx-a11y/no-noninteractive-tabindex */
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }
function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } }
function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }

@@ -326,6 +334,21 @@

if (extraFooterSelections && extraFooterSelections.length) {
if (extraFooterSelections && extraFooterSelections.length || showTime) {
var mergedSelections = [];
if (showTime) {
mergedSelections.push({
label: locale.now,
onClick: function onClick() {
triggerSelect(generateConfig.getNow());
}
});
}
if (extraFooterSelections) {
mergedSelections = [].concat(_toConsumableArray(mergedSelections), _toConsumableArray(extraFooterSelections));
}
extraSelectionNode = React.createElement("ul", {
className: "".concat(prefixCls, "-ranges")
}, extraFooterSelections.map(function (_ref) {
}, mergedSelections.map(function (_ref) {
var label = _ref.label,

@@ -332,0 +355,0 @@ onClick = _ref.onClick;

9

es/RangeContext.d.ts
import * as React from 'react';
import { NullableDateType } from './interface';
export interface FooterSelection {
label: string;
onClick: React.MouseEventHandler<HTMLElement>;
}
interface RangeContextProps {
extraFooterSelections?: {
label: string;
onClick: React.MouseEventHandler<HTMLElement>;
}[];
extraFooterSelections?: FooterSelection[];
/**

@@ -9,0 +10,0 @@ * Set displayed range value style.

"use strict";
/* eslint-disable jsx-a11y/no-noninteractive-tabindex */
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }
function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } }
function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }

@@ -326,6 +334,21 @@

if (extraFooterSelections && extraFooterSelections.length) {
if (extraFooterSelections && extraFooterSelections.length || showTime) {
var mergedSelections = [];
if (showTime) {
mergedSelections.push({
label: locale.now,
onClick: function onClick() {
triggerSelect(generateConfig.getNow());
}
});
}
if (extraFooterSelections) {
mergedSelections = [].concat(_toConsumableArray(mergedSelections), _toConsumableArray(extraFooterSelections));
}
extraSelectionNode = React.createElement("ul", {
className: "".concat(prefixCls, "-ranges")
}, extraFooterSelections.map(function (_ref) {
}, mergedSelections.map(function (_ref) {
var label = _ref.label,

@@ -332,0 +355,0 @@ onClick = _ref.onClick;

import * as React from 'react';
import { NullableDateType } from './interface';
export interface FooterSelection {
label: string;
onClick: React.MouseEventHandler<HTMLElement>;
}
interface RangeContextProps {
extraFooterSelections?: {
label: string;
onClick: React.MouseEventHandler<HTMLElement>;
}[];
extraFooterSelections?: FooterSelection[];
/**

@@ -9,0 +10,0 @@ * Set displayed range value style.

{
"name": "rc-picker",
"version": "0.0.1-alpha.14",
"version": "0.0.1-alpha.15",
"description": "React date & time picker",

@@ -5,0 +5,0 @@ "keywords": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc