Latest updates from IceHrmPro

This commit is contained in:
Thilina Pituwala
2020-05-20 18:47:29 +02:00
parent 60c92d7935
commit 7453a58aad
18012 changed files with 2089245 additions and 10173 deletions
+24
View File
@@ -0,0 +1,24 @@
import * as React from 'react';
export interface LocaleReceiverProps {
componentName?: string;
defaultLocale?: object | Function;
children: (locale: object, localeCode?: string, fullLocale?: object) => React.ReactNode;
}
interface LocaleInterface {
[key: string]: any;
}
export interface LocaleReceiverContext {
antLocale?: LocaleInterface;
}
export default class LocaleReceiver extends React.Component<LocaleReceiverProps> {
static defaultProps: {
componentName: string;
};
static contextType: React.Context<(Partial<import(".").Locale> & {
exist?: boolean | undefined;
}) | undefined>;
getLocale(): any;
getLocaleCode(): any;
render(): React.ReactNode;
}
export {};
+77
View File
@@ -0,0 +1,77 @@
function _typeof(obj) { "@babel/helpers - typeof"; 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); }
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
import * as React from 'react';
import defaultLocaleData from './default';
import LocaleContext from './context';
var LocaleReceiver = /*#__PURE__*/function (_React$Component) {
_inherits(LocaleReceiver, _React$Component);
var _super = _createSuper(LocaleReceiver);
function LocaleReceiver() {
_classCallCheck(this, LocaleReceiver);
return _super.apply(this, arguments);
}
_createClass(LocaleReceiver, [{
key: "getLocale",
value: function getLocale() {
var _this$props = this.props,
componentName = _this$props.componentName,
defaultLocale = _this$props.defaultLocale;
var locale = defaultLocale || defaultLocaleData[componentName || 'global'];
var antLocale = this.context;
var localeFromContext = componentName && antLocale ? antLocale[componentName] : {};
return _extends(_extends({}, typeof locale === 'function' ? locale() : locale), localeFromContext || {});
}
}, {
key: "getLocaleCode",
value: function getLocaleCode() {
var antLocale = this.context;
var localeCode = antLocale && antLocale.locale; // Had use LocaleProvide but didn't set locale
if (antLocale && antLocale.exist && !localeCode) {
return defaultLocaleData.locale;
}
return localeCode;
}
}, {
key: "render",
value: function render() {
return this.props.children(this.getLocale(), this.getLocaleCode(), this.context);
}
}]);
return LocaleReceiver;
}(React.Component);
export { LocaleReceiver as default };
LocaleReceiver.defaultProps = {
componentName: 'global'
};
LocaleReceiver.contextType = LocaleContext;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ar_EG';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ar_EG';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/az_AZ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/az_AZ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/bg_BG';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/bg_BG';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ca_ES';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ca_ES';
export default locale;
+6
View File
@@ -0,0 +1,6 @@
/// <reference types="react" />
import { Locale } from '.';
declare const LocaleContext: import("react").Context<(Partial<Locale> & {
exist?: boolean | undefined;
}) | undefined>;
export default LocaleContext;
+3
View File
@@ -0,0 +1,3 @@
import { createContext } from 'react';
var LocaleContext = createContext(undefined);
export default LocaleContext;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/cs_CZ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/cs_CZ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/da_DK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/da_DK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/de_DE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/de_DE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/default';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/default';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/el_GR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/el_GR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/en_GB';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/en_GB';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/en_US';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/en_US';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/es_ES';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/es_ES';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/et_EE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/et_EE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fa_IR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fa_IR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fi_FI';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fi_FI';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fr_BE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fr_BE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fr_FR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/fr_FR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/he_IL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/he_IL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hi_IN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hi_IN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hr_HR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hr_HR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hu_HU';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hu_HU';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hy_AM';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/hy_AM';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/id_ID';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/id_ID';
export default locale;
+46
View File
@@ -0,0 +1,46 @@
import * as React from 'react';
import { ValidateMessages } from 'rc-field-form/lib/interface';
import { ModalLocale } from '../modal/locale';
import { TransferLocale as TransferLocaleForEmpty } from '../empty';
import { PaginationLocale } from '../pagination/Pagination';
import { TableLocale } from '../table/interface';
import { PopconfirmLocale } from '../popconfirm';
import { UploadLocale } from '../upload/interface';
import { TransferLocale } from '../transfer';
import { PickerLocale as DatePickerLocale } from '../date-picker/generatePicker';
export declare const ANT_MARK = "internalMark";
export interface Locale {
locale: string;
Pagination?: PaginationLocale;
DatePicker?: DatePickerLocale;
TimePicker?: Object;
Calendar?: Object;
Table?: TableLocale;
Modal?: ModalLocale;
Popconfirm?: PopconfirmLocale;
Transfer?: Partial<TransferLocale>;
Select?: Object;
Upload?: UploadLocale;
Empty?: TransferLocaleForEmpty;
global?: Object;
PageHeader?: Object;
Icon?: Object;
Text?: Object;
Form?: {
defaultValidateMessages: ValidateMessages;
};
}
export interface LocaleProviderProps {
locale: Locale;
children?: React.ReactNode;
_ANT_MARK__?: string;
}
export default class LocaleProvider extends React.Component<LocaleProviderProps, any> {
static defaultProps: {
locale: {};
};
constructor(props: LocaleProviderProps);
componentDidUpdate(prevProps: LocaleProviderProps): void;
componentWillUnmount(): void;
render(): JSX.Element;
}
+81
View File
@@ -0,0 +1,81 @@
function _typeof(obj) { "@babel/helpers - typeof"; 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); }
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
import * as React from 'react';
import warning from '../_util/warning';
import { changeConfirmLocale } from '../modal/locale';
import LocaleContext from './context';
export var ANT_MARK = 'internalMark';
var LocaleProvider = /*#__PURE__*/function (_React$Component) {
_inherits(LocaleProvider, _React$Component);
var _super = _createSuper(LocaleProvider);
function LocaleProvider(props) {
var _this;
_classCallCheck(this, LocaleProvider);
_this = _super.call(this, props);
changeConfirmLocale(props.locale && props.locale.Modal);
warning(props._ANT_MARK__ === ANT_MARK, 'LocaleProvider', '`LocaleProvider` is deprecated. Please use `locale` with `ConfigProvider` instead: http://u.ant.design/locale');
return _this;
}
_createClass(LocaleProvider, [{
key: "componentDidUpdate",
value: function componentDidUpdate(prevProps) {
var locale = this.props.locale;
if (prevProps.locale !== locale) {
changeConfirmLocale(locale && locale.Modal);
}
}
}, {
key: "componentWillUnmount",
value: function componentWillUnmount() {
changeConfirmLocale();
}
}, {
key: "render",
value: function render() {
var _this$props = this.props,
locale = _this$props.locale,
children = _this$props.children;
return /*#__PURE__*/React.createElement(LocaleContext.Provider, {
value: _extends(_extends({}, locale), {
exist: true
})
}, children);
}
}]);
return LocaleProvider;
}(React.Component);
export { LocaleProvider as default };
LocaleProvider.defaultProps = {
locale: {}
};
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/is_IS';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/is_IS';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/it_IT';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/it_IT';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ja_JP';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ja_JP';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/kn_IN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/kn_IN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ko_KR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ko_KR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ku_IQ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ku_IQ';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/lv_LV';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/lv_LV';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/mk_MK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/mk_MK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/mn_MN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/mn_MN';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ms_MY';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ms_MY';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nb_NO';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nb_NO';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ne_NP';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ne_NP';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nl_BE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nl_BE';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nl_NL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/nl_NL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pl_PL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pl_PL';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pt_BR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pt_BR';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pt_PT';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/pt_PT';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ro_RO';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ro_RO';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ru_RU';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/ru_RU';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sk_SK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sk_SK';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sl_SI';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sl_SI';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sr_RS';
export default locale;
+2
View File
@@ -0,0 +1,2 @@
import locale from '../locale/sr_RS';
export default locale;
+1
View File
@@ -0,0 +1 @@
import './index.css';
+4
View File
@@ -0,0 +1,4 @@
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
/* stylelint-disable no-duplicate-selectors */
/* stylelint-disable */
/* stylelint-disable declaration-bang-space-before,no-duplicate-selectors,string-no-newline */
+1
View File
@@ -0,0 +1 @@
import './index.less';
+1
View File
@@ -0,0 +1 @@
import './index.less';

Some files were not shown because too many files have changed in this diff Show More