Gathering detailed insights and metrics for @micromint1npm/dolorum-unde-dolor
Gathering detailed insights and metrics for @micromint1npm/dolorum-unde-dolor
Gathering detailed insights and metrics for @micromint1npm/dolorum-unde-dolor
Gathering detailed insights and metrics for @micromint1npm/dolorum-unde-dolor
npm install @micromint1npm/dolorum-unde-dolor
Typescript
Module System
Node Version
NPM Version
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
3,015 Commits
1 Watchers
1 Branches
1 Contributors
Updated on May 23, 2025
Latest Version
1.0.0
Package Id
@micromint1npm/dolorum-unde-dolor@1.0.0
Unpacked Size
23.03 kB
Size
7.72 kB
File Count
8
NPM Version
10.5.0
Node Version
20.12.2
Published on
May 11, 2024
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
30
Common Utils For React Component.
(...functions): Function
Create a function which will call all the functions with it's arguments from left to right.
1import createChainedFunction from '@micromint1npm/dolorum-unde-dolor/lib/createChainedFunction';
(prop: string, instead: string, component: string): void
Log an error message to warn developers that prop
is deprecated.
1import deprecated from '@micromint1npm/dolorum-unde-dolor/lib/deprecated';
(config: Object): Object
To generate a mixin which will render specific component into specific container automatically.
1import getContainerRenderMixin from '@micromint1npm/dolorum-unde-dolor/lib/getContainerRenderMixin';
Fields in config
and their meanings.
Field | Type | Description | Default |
---|---|---|---|
autoMount | boolean | Whether to render component into container automatically | true |
autoDestroy | boolean | Whether to remove container automatically while the component is unmounted | true |
isVisible | (instance): boolean | A function to get current visibility of the component | - |
isForceRender | (instance): boolean | A function to determine whether to render popup even it's not visible | - |
getComponent | (instance, extra): ReactNode | A function to get the component which will be rendered into container | - |
getContainer | (instance): HTMLElement | A function to get the container |
Render children to the specific container;
1import Portal from '@micromint1npm/dolorum-unde-dolor/lib/Portal';
Props:
Prop | Type | Description | Default |
---|---|---|---|
children | ReactChildren | Content render to the container | - |
getContainer | (): HTMLElement | A function to get the container | - |
(fresh?: boolean): number
Get the width of scrollbar.
1import getScrollBarSize from '@micromint1npm/dolorum-unde-dolor/lib/getScrollBarSize';
(): string
To generate a global unique id across current application.
1import guid from '@micromint1npm/dolorum-unde-dolor/lib/guid';
(props: Object): Object
Pick valid HTML attributes and events from props.
1import pickAttrs from '@micromint1npm/dolorum-unde-dolor/lib/pickAttrs';
(msg: string): void
A shallow wrapper of console.warn
.
1import warn from '@micromint1npm/dolorum-unde-dolor/lib/warn';
(valid: boolean, msg: string): void
A shallow wrapper of warning, but only warning once for the same message.
1import warning, { noteOnce } from '@micromint1npm/dolorum-unde-dolor/lib/warning'; 2 3warning(false, '[antd Component] test hello world'); 4 5// Low level note 6noteOnce(false, '[antd Component] test hello world');
A collection of functions to operate React elements' children.
(children): children
Return a shallow copy of children.
1import mapSelf from '@micromint1npm/dolorum-unde-dolor/lib/Children/mapSelf';
(children: ReactNode[]): ReactNode[]
Convert children into an array.
1import toArray from '@micromint1npm/dolorum-unde-dolor/lib/Children/toArray';
A collection of functions to operate DOM elements.
(target: ReactNode, eventType: string, listener: Function): { remove: Function }
A shallow wrapper of add-dom-event-listener.
1import addEventlistener from '@micromint1npm/dolorum-unde-dolor/lib/Dom/addEventlistener';
(): boolean
Check if DOM is available.
1import canUseDom from '@micromint1npm/dolorum-unde-dolor/lib/Dom/canUseDom';
A collection of functions to operate DOM nodes' class name.
hasClass(node: HTMLElement, className: string): boolean
addClass(node: HTMLElement, className: string): void
removeClass(node: HTMLElement, className: string): void
1import cssClass from '@micromint1npm/dolorum-unde-dolor/lib/Dom/class;
(root: HTMLElement, node: HTMLElement): boolean
Check if node is equal to root or in the subtree of root.
1import contains from '@micromint1npm/dolorum-unde-dolor/lib/Dom/contains';
A collection of functions to get or set css styles.
get(node: HTMLElement, name?: string): any
set(node: HTMLElement, name?: string, value: any) | set(node, object)
getOuterWidth(el: HTMLElement): number
getOuterHeight(el: HTMLElement): number
getDocSize(): { width: number, height: number }
getClientSize(): { width: number, height: number }
getScroll(): { scrollLeft: number, scrollTop: number }
getOffset(node: HTMLElement): { left: number, top: number }
1import css from '@micromint1npm/dolorum-unde-dolor/lib/Dom/css';
A collection of functions to operate focus status of DOM node.
saveLastFocusNode(): void
clearLastFocusNode(): void
backLastFocusNode(): void
getFocusNodeList(node: HTMLElement): HTMLElement[]
get a list of focusable nodes from the subtree of node.limitTabRange(node: HTMLElement, e: Event): void
1import focus from '@micromint1npm/dolorum-unde-dolor/lib/Dom/focus';
{ animation: boolean | Object, transition: boolean | Object }
A flag to tell whether current environment supports animationend
or transitionend
.
1import support from '@micromint1npm/dolorum-unde-dolor/lib/Dom/support';
Enum
Enum of KeyCode, please check the definition of it.
1import KeyCode from '@micromint1npm/dolorum-unde-dolor/lib/KeyCode';
(e: Event): boolean
Whether text and modified key is entered at the same time.
(keyCode: KeyCode): boolean
Whether character is entered.
ScrollLocker<{lock: (options: {container: HTMLElement}) => void, unLock: () => void}>
improve shake when page scroll bar hidden.
ScrollLocker
change body style, and add a class ant-scrolling-effect
when called, so if you page look abnormal, please check this;
1import ScrollLocker from '@micromint1npm/dolorum-unde-dolor/lib/Dom/scrollLocker'; 2 3const scrollLocker = new ScrollLocker(); 4 5// lock 6scrollLocker.lock() 7 8// unLock 9scrollLocker.unLock()
No vulnerabilities found.
No security vulnerabilities found.