UNPKG

ng-zorro-antd

Version:

An enterprise-class UI components based on Ant Design and Angular

1 lines 49.1 kB
{"version":3,"file":"ng-zorro-antd-core-util.mjs","sources":["../../components/core/util/array.ts","../../components/core/util/check.ts","../../components/core/util/convert.ts","../../components/core/util/dom.ts","../../components/core/util/getMentions.ts","../../components/core/util/string.ts","../../components/core/util/is-promise.ts","../../components/core/util/number.ts","../../components/core/util/scroll-into-view-if-needed.ts","../../components/core/util/textarea-caret-position.ts","../../components/core/util/style.ts","../../components/core/util/text-measure.ts","../../components/core/util/measure-scrollbar.ts","../../components/core/util/ensure-in-bounds.ts","../../components/core/util/tick.ts","../../components/core/util/observable.ts","../../components/core/util/public-api.ts","../../components/core/util/ng-zorro-antd-core-util.ts"],"sourcesContent":["/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nexport function toArray<T>(value: T | T[]): T[] {\n let ret: T[];\n if (value == null) {\n ret = [];\n } else if (!Array.isArray(value)) {\n ret = [value];\n } else {\n ret = value;\n }\n return ret;\n}\n\nexport function arraysEqual<T>(array1: T[], array2: T[]): boolean {\n if (!array1 || !array2 || array1.length !== array2.length) {\n return false;\n }\n\n const len = array1.length;\n for (let i = 0; i < len; i++) {\n if (array1[i] !== array2[i]) {\n return false;\n }\n }\n return true;\n}\n\nexport function shallowCopyArray<T>(source: T[]): T[] {\n return source.slice();\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { TemplateRef } from '@angular/core';\n\nimport { IndexableObject, NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function isNotNil<T>(value: T): value is NonNullable<T> {\n return typeof value !== 'undefined' && value !== null;\n}\n\nexport function isNil(value: unknown): value is null | undefined {\n return typeof value === 'undefined' || value === null;\n}\n\n/**\n * Examine if two objects are shallowly equaled.\n */\nexport function shallowEqual(objA?: IndexableObject, objB?: IndexableObject): boolean {\n if (objA === objB) {\n return true;\n }\n\n if (typeof objA !== 'object' || !objA || typeof objB !== 'object' || !objB) {\n return false;\n }\n\n const keysA = Object.keys(objA);\n const keysB = Object.keys(objB);\n\n if (keysA.length !== keysB.length) {\n return false;\n }\n\n const bHasOwnProperty = Object.prototype.hasOwnProperty.bind(objB);\n\n // eslint-disable-next-line @typescript-eslint/prefer-for-of\n for (let idx = 0; idx < keysA.length; idx++) {\n const key = keysA[idx];\n if (!bHasOwnProperty(key)) {\n return false;\n }\n if (objA[key] !== objB[key]) {\n return false;\n }\n }\n\n return true;\n}\n\nexport function isNonEmptyString(value: NzSafeAny): boolean {\n return typeof value === 'string' && value !== '';\n}\n\nexport function isTemplateRef(value: NzSafeAny): boolean {\n return value instanceof TemplateRef;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { coerceBooleanProperty, coerceCssPixelValue, _isNumberValue } from '@angular/cdk/coercion';\n\nimport { warn } from 'ng-zorro-antd/core/logger';\nimport { FunctionProp, NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function toBoolean(value: boolean | string): boolean {\n return coerceBooleanProperty(value);\n}\n\nexport function toNumber(value: number | string): number;\nexport function toNumber<D>(value: number | string, fallback: D): number | D;\nexport function toNumber(value: number | string, fallbackValue: number = 0): number {\n return _isNumberValue(value) ? Number(value) : fallbackValue;\n}\n\nexport function toCssPixel(value: number | string): string {\n return coerceCssPixelValue(value);\n}\n\n// eslint-disable no-invalid-this\n\n/**\n * Get the function-property type's value\n */\nexport function valueFunctionProp<T>(prop: FunctionProp<T> | T, ...args: NzSafeAny[]): T {\n return typeof prop === 'function' ? (prop as FunctionProp<T>)(...args) : prop;\n}\n\nfunction propDecoratorFactory<T, D>(\n name: string,\n fallback: (v: T) => D\n): (target: NzSafeAny, propName: string) => void {\n function propDecorator(\n target: NzSafeAny,\n propName: string,\n originalDescriptor?: TypedPropertyDescriptor<NzSafeAny>\n ): NzSafeAny {\n const privatePropName = `$$__zorroPropDecorator__${propName}`;\n\n if (Object.prototype.hasOwnProperty.call(target, privatePropName)) {\n warn(`The prop \"${privatePropName}\" is already exist, it will be overrided by ${name} decorator.`);\n }\n\n Object.defineProperty(target, privatePropName, {\n configurable: true,\n writable: true\n });\n\n return {\n get(): string {\n return originalDescriptor && originalDescriptor.get\n ? originalDescriptor.get.bind(this)()\n : this[privatePropName];\n },\n set(value: T): void {\n if (originalDescriptor && originalDescriptor.set) {\n originalDescriptor.set.bind(this)(fallback(value));\n }\n this[privatePropName] = fallback(value);\n }\n };\n }\n\n return propDecorator;\n}\n\n/**\n * Input decorator that handle a prop to do get/set automatically with toBoolean\n *\n * Why not using @InputBoolean alone without @Input? AOT needs @Input to be visible\n *\n * @howToUse\n * ```\n * @Input() @InputBoolean() visible: boolean = false;\n *\n * // Act as below:\n * // @Input()\n * // get visible() { return this.__visible; }\n * // set visible(value) { this.__visible = value; }\n * // __visible = false;\n * ```\n */\nexport function InputBoolean(): NzSafeAny {\n return propDecoratorFactory('InputBoolean', toBoolean);\n}\n\nexport function InputCssPixel(): NzSafeAny {\n return propDecoratorFactory('InputCssPixel', toCssPixel);\n}\n\nexport function InputNumber(fallbackValue?: NzSafeAny): NzSafeAny {\n return propDecoratorFactory('InputNumber', (value: string | number) => toNumber(value, fallbackValue));\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\n/**\n * This module provides utility functions to query DOM information or\n * set properties.\n */\n\nimport { Observable } from 'rxjs';\n\n/**\n * Silent an event by stopping and preventing it.\n */\nexport function silentEvent(e: Event): void {\n e.stopPropagation();\n e.preventDefault();\n}\n\nexport function getElementOffset(elem: HTMLElement): { top: number; left: number } {\n if (!elem.getClientRects().length) {\n return { top: 0, left: 0 };\n }\n\n const rect = elem.getBoundingClientRect();\n const win = elem.ownerDocument!.defaultView;\n return {\n top: rect.top + win!.pageYOffset,\n left: rect.left + win!.pageXOffset\n };\n}\n\n/**\n * Investigate if an event is a `TouchEvent`.\n */\nexport function isTouchEvent(event: MouseEvent | TouchEvent): event is TouchEvent {\n return event.type.startsWith('touch');\n}\n\nexport function getEventPosition(event: MouseEvent | TouchEvent): MouseEvent | Touch {\n return isTouchEvent(event) ? event.touches[0] || event.changedTouches[0] : event;\n}\n\nexport interface MouseTouchObserverConfig {\n end: string;\n move: string;\n pluckKey: string[];\n start: string;\n\n end$?: Observable<Event>;\n moveResolved$?: Observable<number>;\n startPlucked$?: Observable<number>;\n\n filter?(e: Event): boolean;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nexport function getRegExp(prefix: string | string[]): RegExp {\n const prefixArray = Array.isArray(prefix) ? prefix : [prefix];\n let prefixToken = prefixArray.join('').replace(/(\\$|\\^)/g, '\\\\$1');\n\n if (prefixArray.length > 1) {\n prefixToken = `[${prefixToken}]`;\n }\n\n return new RegExp(`(\\\\s|^)(${prefixToken})[^\\\\s]*`, 'g');\n}\n\nexport function getMentions(value: string, prefix: string | string[] = '@'): string[] {\n if (typeof value !== 'string') {\n return [];\n }\n const regex = getRegExp(prefix);\n const mentions = value.match(regex);\n return mentions !== null ? mentions.map(e => e.trim()) : [];\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\n/**\n * Much like lodash.\n */\nexport function padStart(toPad: string, length: number, element: string): string {\n if (toPad.length > length) {\n return toPad;\n }\n\n const joined = `${getRepeatedElement(length, element)}${toPad}`;\n return joined.slice(joined.length - length, joined.length);\n}\n\nexport function padEnd(toPad: string, length: number, element: string): string {\n const joined = `${toPad}${getRepeatedElement(length, element)}`;\n return joined.slice(0, length);\n}\n\nexport function getRepeatedElement(length: number, element: string): string {\n return Array(length).fill(element).join('');\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function isPromise<T>(obj: NzSafeAny): obj is Promise<T> {\n return !!obj && typeof obj.then === 'function' && typeof obj.catch === 'function';\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function getPercent(min: number, max: number, value: number): number {\n return ((value - min) / (max - min)) * 100;\n}\n\nexport function getPrecision(num: number): number {\n const numStr = num.toString();\n const dotIndex = numStr.indexOf('.');\n return dotIndex >= 0 ? numStr.length - dotIndex - 1 : 0;\n}\n\nexport function ensureNumberInRange(num: number, min: number, max: number): number {\n if (isNaN(num) || num < min) {\n return min;\n } else if (num > max) {\n return max;\n } else {\n return num;\n }\n}\n\nexport function isNumberFinite(value: NzSafeAny): boolean {\n return typeof value === 'number' && isFinite(value);\n}\n\nexport function toDecimal(value: number, decimal: number): number {\n return Math.round(value * Math.pow(10, decimal)) / Math.pow(10, decimal);\n}\n\nexport function sum(input: number[], initial: number = 0): number {\n return input.reduce((previous: number, current: number) => previous + current, initial);\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport function scrollIntoView(node: HTMLElement): void {\n const nodeAsAny = node as NzSafeAny;\n if (nodeAsAny.scrollIntoViewIfNeeded) {\n /* eslint-disable-next-line @typescript-eslint/dot-notation */\n nodeAsAny.scrollIntoViewIfNeeded(false);\n return;\n }\n if (node.scrollIntoView) {\n node.scrollIntoView(false);\n return;\n }\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NzSafeAny } from 'ng-zorro-antd/core/types';\n\n// from https://github.com/component/textarea-caret-position\n\n// We'll copy the properties below into the mirror div.\n// Note that some browsers, such as Firefox, do not concatenate properties\n// into their shorthand (e.g. padding-top, padding-bottom etc. -> padding),\n// so we have to list every single property explicitly.\nexport const properties = [\n 'direction', // RTL support\n 'boxSizing',\n 'width', // on Chrome and IE, exclude the scrollbar, so the mirror div wraps exactly as the textarea does\n 'height',\n 'overflowX',\n 'overflowY', // copy the scrollbar for IE\n\n 'borderTopWidth',\n 'borderRightWidth',\n 'borderBottomWidth',\n 'borderLeftWidth',\n 'borderStyle',\n\n 'paddingTop',\n 'paddingRight',\n 'paddingBottom',\n 'paddingLeft',\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/font\n 'fontStyle',\n 'fontVariant',\n 'fontWeight',\n 'fontStretch',\n 'fontSize',\n 'fontSizeAdjust',\n 'lineHeight',\n 'fontFamily',\n\n 'textAlign',\n 'textTransform',\n 'textIndent',\n 'textDecoration', // might not make a difference, but better be safe\n\n 'letterSpacing',\n 'wordSpacing',\n\n 'tabSize',\n 'MozTabSize'\n];\n\nconst isBrowser = typeof window !== 'undefined';\n\nconst isFirefox = isBrowser && (window as NzSafeAny).mozInnerScreenX != null;\n\nconst _parseInt = (str: string): number => parseInt(str, 10);\n\nexport interface Coordinates {\n top: number;\n left: number;\n height: number;\n}\n\nexport function getCaretCoordinates(\n element: HTMLInputElement | HTMLTextAreaElement,\n position: number,\n options?: { debug?: boolean }\n): Coordinates {\n if (!isBrowser) {\n throw new Error('textarea-caret-position#getCaretCoordinates should only be called in a browser');\n }\n\n const debug = (options && options.debug) || false;\n if (debug) {\n const el = document.querySelector('#input-textarea-caret-position-mirror-div');\n if (el) {\n el.parentNode!.removeChild(el);\n }\n }\n\n // The mirror div will replicate the textarea's style\n const div = document.createElement('div');\n div.id = 'input-textarea-caret-position-mirror-div';\n document.body.appendChild(div);\n\n const style = div.style;\n\n const computed = window.getComputedStyle ? window.getComputedStyle(element) : (element as NzSafeAny).currentStyle; // currentStyle for IE < 9\n const isInput = element.nodeName === 'INPUT';\n\n // Default textarea styles\n style.whiteSpace = 'pre-wrap';\n if (!isInput) {\n style.wordWrap = 'break-word'; // only for textarea-s\n }\n\n // Position off-screen\n style.position = 'absolute'; // required to return coordinates properly\n if (!debug) {\n style.visibility = 'hidden';\n } // not 'display: none' because we want rendering\n\n // Transfer the element's properties to the div\n properties.forEach((prop: string) => {\n if (isInput && prop === 'lineHeight') {\n // Special case for <input>s because text is rendered centered and line height may be != height\n style.lineHeight = computed.height;\n } else {\n // @ts-ignore\n style[prop] = computed[prop];\n }\n });\n\n if (isFirefox) {\n // Firefox lies about the overflow property for textareas: https://bugzilla.mozilla.org/show_bug.cgi?id=984275\n if (element.scrollHeight > _parseInt(computed.height)) {\n style.overflowY = 'scroll';\n }\n } else {\n style.overflow = 'hidden'; // for Chrome to not render a scrollbar; IE keeps overflowY = 'scroll'\n }\n\n div.textContent = element.value.substring(0, position);\n // The second special handling for input type=\"text\" vs textarea:\n // spaces need to be replaced with non-breaking spaces - http://stackoverflow.com/a/13402035/1269037\n if (isInput) {\n div.textContent = div.textContent.replace(/\\s/g, '\\u00a0');\n }\n\n const span = document.createElement('span');\n // Wrapping must be replicated *exactly*, including when a long word gets\n // onto the next line, with whitespace at the end of the line before (#7).\n // The *only* reliable way to do that is to copy the *entire* rest of the\n // textarea's content into the <span> created at the caret position.\n // For inputs, just '.' would be enough, but no need to bother.\n span.textContent = element.value.substring(position) || '.'; // || because a completely empty faux span doesn't render at all\n div.appendChild(span);\n\n const coordinates = {\n top: span.offsetTop + _parseInt(computed.borderTopWidth),\n left: span.offsetLeft + _parseInt(computed.borderLeftWidth),\n height: _parseInt(computed.lineHeight)\n };\n\n if (debug) {\n span.style.backgroundColor = '#eee';\n createDebugEle(element, coordinates);\n } else {\n document.body.removeChild(div);\n }\n\n return coordinates;\n}\n\nexport function createDebugEle(element: HTMLInputElement | HTMLTextAreaElement, coordinates: Coordinates): void {\n const fontSize = getComputedStyle(element).getPropertyValue('font-size');\n const rect: HTMLSpanElement = (document.querySelector('#DEBUG') as HTMLSpanElement) || document.createElement('div');\n document.body.appendChild(rect);\n rect.id = 'DEBUG';\n rect.style.position = 'absolute';\n rect.style.backgroundColor = 'red';\n rect.style.height = fontSize;\n rect.style.width = '1px';\n rect.style.top = `${\n element.getBoundingClientRect().top - element.scrollTop + window.pageYOffset + coordinates.top\n }px`;\n rect.style.left = `${\n element.getBoundingClientRect().left - element.scrollLeft + window.pageXOffset + coordinates.left\n }px`;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NgStyleInterface } from 'ng-zorro-antd/core/types';\n\nexport function isStyleSupport(styleName: string | string[]): boolean {\n if (typeof window !== 'undefined' && window.document && window.document.documentElement) {\n const styleNameList = Array.isArray(styleName) ? styleName : [styleName];\n const { documentElement } = window.document;\n\n return styleNameList.some(name => name in documentElement.style);\n }\n return false;\n}\n\nexport function getStyleAsText(styles?: NgStyleInterface): string {\n if (!styles) {\n return '';\n }\n\n return Object.keys(styles)\n .map(key => {\n const val = styles[key];\n return `${key}:${typeof val === 'string' ? val : `${val}px`}`;\n })\n .join(';');\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { NzSafeAny } from 'ng-zorro-antd/core/types';\n\nexport interface MeasureResult {\n finished: boolean;\n node: Node | null;\n}\n\n// We only handle element & text node.\nconst ELEMENT_NODE = 1;\nconst TEXT_NODE = 3;\nconst COMMENT_NODE = 8;\n\nlet ellipsisContainer: HTMLParagraphElement;\n\nconst wrapperStyle = {\n padding: '0',\n margin: '0',\n display: 'inline',\n lineHeight: 'inherit'\n};\n\nexport function pxToNumber(value: string | null): number {\n if (!value) {\n return 0;\n }\n\n const match = value.match(/^\\d*(\\.\\d*)?/);\n\n return match ? Number(match[0]) : 0;\n}\n\nfunction styleToString(style: CSSStyleDeclaration): string {\n // There are some different behavior between Firefox & Chrome.\n // We have to handle this ourself.\n const styleNames: string[] = Array.prototype.slice.apply(style);\n return styleNames.map(name => `${name}: ${style.getPropertyValue(name)};`).join('');\n}\n\nfunction mergeChildren(children: Node[]): Node[] {\n const childList: Node[] = [];\n\n children.forEach((child: Node) => {\n const prevChild = childList[childList.length - 1];\n if (prevChild && child.nodeType === TEXT_NODE && prevChild.nodeType === TEXT_NODE) {\n (prevChild as Text).data += (child as Text).data;\n } else {\n childList.push(child);\n }\n });\n\n return childList;\n}\n\nexport function measure(\n originEle: HTMLElement,\n rows: number,\n contentNodes: Node[],\n fixedContent: HTMLElement[],\n ellipsisStr: string,\n suffixStr: string = ''\n): { contentNodes: Node[]; text: string; ellipsis: boolean } {\n if (!ellipsisContainer) {\n ellipsisContainer = document.createElement('div');\n ellipsisContainer.setAttribute('aria-hidden', 'true');\n document.body.appendChild(ellipsisContainer);\n }\n\n // Get origin style\n const originStyle = window.getComputedStyle(originEle);\n const originCSS = styleToString(originStyle);\n const lineHeight = pxToNumber(originStyle.lineHeight);\n const maxHeight = Math.round(\n lineHeight * (rows + 1) + pxToNumber(originStyle.paddingTop) + pxToNumber(originStyle.paddingBottom)\n );\n // Set shadow\n ellipsisContainer.setAttribute('style', originCSS);\n ellipsisContainer.style.position = 'fixed';\n ellipsisContainer.style.left = '0';\n ellipsisContainer.style.height = 'auto';\n ellipsisContainer.style.minHeight = 'auto';\n ellipsisContainer.style.maxHeight = 'auto';\n ellipsisContainer.style.top = '-999999px';\n ellipsisContainer.style.zIndex = '-1000';\n\n // clean up css overflow\n ellipsisContainer.style.textOverflow = 'clip';\n ellipsisContainer.style.whiteSpace = 'normal';\n (ellipsisContainer.style as NzSafeAny).webkitLineClamp = 'none';\n\n const contentList = mergeChildren(contentNodes);\n const container = document.createElement('div');\n const contentContainer = document.createElement('span');\n const suffixContainer = document.createTextNode(suffixStr);\n const fixedContainer = document.createElement('span');\n\n // Add styles in container\n Object.assign(container.style, wrapperStyle);\n Object.assign(contentContainer.style, wrapperStyle);\n Object.assign(fixedContainer.style, wrapperStyle);\n\n contentList.forEach(n => {\n contentContainer.appendChild(n);\n });\n\n contentContainer.appendChild(suffixContainer);\n\n fixedContent.forEach(node => {\n fixedContainer.appendChild(node.cloneNode(true));\n });\n container.appendChild(contentContainer);\n container.appendChild(fixedContainer);\n\n // Render in the fake container\n ellipsisContainer.appendChild(container);\n\n // Check if ellipsis in measure div is height enough for content\n function inRange(): boolean {\n return ellipsisContainer.offsetHeight < maxHeight;\n }\n\n if (inRange()) {\n const text = ellipsisContainer.innerHTML;\n ellipsisContainer.removeChild(container);\n return { contentNodes, text, ellipsis: false };\n }\n\n // We should clone the childNode since they're controlled by React and we can't reuse it without warning\n const childNodes: ChildNode[] = Array.prototype.slice\n .apply(ellipsisContainer.childNodes[0].childNodes[0].cloneNode(true).childNodes)\n .filter(({ nodeType }: ChildNode) => nodeType !== COMMENT_NODE);\n const fixedNodes: ChildNode[] = Array.prototype.slice.apply(\n ellipsisContainer.childNodes[0].childNodes[1].cloneNode(true).childNodes\n );\n ellipsisContainer.removeChild(container);\n\n // ========================= Find match ellipsis content =========================\n ellipsisContainer.innerHTML = '';\n\n // Create origin content holder\n const ellipsisContentHolder = document.createElement('span');\n ellipsisContainer.appendChild(ellipsisContentHolder);\n const ellipsisTextNode = document.createTextNode(ellipsisStr + suffixStr);\n ellipsisContentHolder.appendChild(ellipsisTextNode);\n\n fixedNodes.forEach(childNode => {\n ellipsisContainer.appendChild(childNode);\n });\n\n // Append before fixed nodes\n function appendChildNode(node: ChildNode): void {\n ellipsisContentHolder.insertBefore(node, ellipsisTextNode);\n }\n\n // Get maximum text\n function measureText(\n textNode: Text,\n fullText: string,\n startLoc: number = 0,\n endLoc: number = fullText.length,\n lastSuccessLoc: number = 0\n ): MeasureResult {\n const midLoc = Math.floor((startLoc + endLoc) / 2);\n textNode.textContent = fullText.slice(0, midLoc);\n\n if (startLoc >= endLoc - 1) {\n // Loop when step is small\n for (let step = endLoc; step >= startLoc; step -= 1) {\n const currentStepText = fullText.slice(0, step);\n textNode.textContent = currentStepText;\n\n if (inRange() || !currentStepText) {\n return step === fullText.length\n ? {\n finished: false,\n node: document.createTextNode(fullText)\n }\n : {\n finished: true,\n node: document.createTextNode(currentStepText)\n };\n }\n }\n }\n if (inRange()) {\n return measureText(textNode, fullText, midLoc, endLoc, midLoc);\n } else {\n return measureText(textNode, fullText, startLoc, midLoc, lastSuccessLoc);\n }\n }\n\n function measureNode(childNode: ChildNode, index: number): MeasureResult {\n const type = childNode.nodeType;\n\n if (type === ELEMENT_NODE) {\n // We don't split element, it will keep if whole element can be displayed.\n // appendChildNode(childNode);\n if (inRange()) {\n return {\n finished: false,\n node: contentList[index]\n };\n }\n\n // Clean up if can not pull in\n ellipsisContentHolder.removeChild(childNode);\n return {\n finished: true,\n node: null\n };\n } else if (type === TEXT_NODE) {\n const fullText = childNode.textContent || '';\n const textNode = document.createTextNode(fullText);\n appendChildNode(textNode);\n return measureText(textNode, fullText);\n }\n\n // Not handle other type of content\n // PS: This code should not be attached after react 16\n return {\n finished: false,\n node: null\n };\n }\n\n const ellipsisNodes: Node[] = [];\n childNodes.some((childNode, index) => {\n const { finished, node } = measureNode(childNode, index);\n if (node) {\n ellipsisNodes.push(node);\n }\n return finished;\n });\n const result = {\n contentNodes: ellipsisNodes,\n text: ellipsisContainer.innerHTML,\n ellipsis: true\n };\n while (ellipsisContainer.firstChild) {\n ellipsisContainer.removeChild(ellipsisContainer.firstChild);\n }\n return result;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nlet scrollbarVerticalSize: number;\nlet scrollbarHorizontalSize: number;\n\n// Measure scrollbar width for padding body during modal show/hide\nconst scrollbarMeasure = {\n position: 'absolute',\n top: '-9999px',\n width: '50px',\n height: '50px'\n};\n\nexport function measureScrollbar(direction: 'vertical' | 'horizontal' = 'vertical', prefix: string = 'ant'): number {\n if (typeof document === 'undefined' || typeof window === 'undefined') {\n return 0;\n }\n const isVertical = direction === 'vertical';\n if (isVertical && scrollbarVerticalSize) {\n return scrollbarVerticalSize;\n } else if (!isVertical && scrollbarHorizontalSize) {\n return scrollbarHorizontalSize;\n }\n const scrollDiv = document.createElement('div');\n Object.keys(scrollbarMeasure).forEach(scrollProp => {\n // @ts-ignore\n scrollDiv.style[scrollProp] = scrollbarMeasure[scrollProp];\n });\n // apply hide scrollbar className ahead\n scrollDiv.className = `${prefix}-hide-scrollbar scroll-div-append-to-body`;\n // Append related overflow style\n if (isVertical) {\n scrollDiv.style.overflowY = 'scroll';\n } else {\n scrollDiv.style.overflowX = 'scroll';\n }\n document.body.appendChild(scrollDiv);\n let size = 0;\n if (isVertical) {\n size = scrollDiv.offsetWidth - scrollDiv.clientWidth;\n scrollbarVerticalSize = size;\n } else {\n size = scrollDiv.offsetHeight - scrollDiv.clientHeight;\n scrollbarHorizontalSize = size;\n }\n\n document.body.removeChild(scrollDiv);\n return size;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nexport function ensureInBounds(value: number, boundValue: number): number {\n return value ? (value < boundValue ? value : boundValue) : boundValue;\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { Observable, Subject } from 'rxjs';\nimport { take } from 'rxjs/operators';\n\nexport function inNextTick(): Observable<void> {\n const timer = new Subject<void>();\n Promise.resolve().then(() => timer.next());\n return timer.pipe(take(1));\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nimport { from, isObservable, Observable, of } from 'rxjs';\n\nimport { isPromise } from './is-promise';\n\nexport function wrapIntoObservable<T>(value: T | Promise<T> | Observable<T>): Observable<T> {\n if (isObservable(value)) {\n return value;\n }\n\n if (isPromise(value)) {\n // Use `Promise.resolve()` to wrap promise-like instances.\n return from(Promise.resolve(value));\n }\n\n return of(value);\n}\n","/**\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE\n */\n\nexport * from './array';\nexport * from './check';\nexport * from './convert';\nexport * from './dom';\nexport * from './getMentions';\nexport * from './string';\nexport * from './is-promise';\nexport * from './number';\nexport * from './scroll-into-view-if-needed';\nexport * from './textarea-caret-position';\nexport * from './style';\nexport * from './text-measure';\nexport * from './measure-scrollbar';\nexport * from './ensure-in-bounds';\nexport * from './tick';\nexport * from './observable';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA;;;;SAKgB,OAAO,CAAI,KAAc;IACvC,IAAI,GAAQ,CAAC;IACb,IAAI,KAAK,IAAI,IAAI,EAAE;QACjB,GAAG,GAAG,EAAE,CAAC;KACV;SAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;QAChC,GAAG,GAAG,CAAC,KAAK,CAAC,CAAC;KACf;SAAM;QACL,GAAG,GAAG,KAAK,CAAC;KACb;IACD,OAAO,GAAG,CAAC;AACb,CAAC;SAEe,WAAW,CAAI,MAAW,EAAE,MAAW;IACrD,IAAI,CAAC,MAAM,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC,MAAM,KAAK,MAAM,CAAC,MAAM,EAAE;QACzD,OAAO,KAAK,CAAC;KACd;IAED,MAAM,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC;IAC1B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAA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