Skip to content

Commit 6f024fd

Browse files
committed
perf(ui:select): optimize performance
1 parent c1f1297 commit 6f024fd

14 files changed

Lines changed: 607 additions & 560 deletions

File tree

.versionrc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
"types": [
33
{ "type": "feat", "section": "Features" },
44
{ "type": "fix", "section": "Bug Fixes" },
5-
{ "type": "chore", "section": "Miscellaneous Chores", "hidden": false },
6-
{ "type": "docs", "section": "Miscellaneous Chores", "hidden": false },
7-
{ "type": "style", "section": "Miscellaneous Chores", "hidden": false },
8-
{ "type": "refactor", "section": "Miscellaneous Chores", "hidden": false },
9-
{ "type": "perf", "section": "Miscellaneous Chores", "hidden": false },
10-
{ "type": "test", "section": "Miscellaneous Chores", "hidden": false }
5+
{ "type": "chore", "hidden": true },
6+
{ "type": "docs", "hidden": true },
7+
{ "type": "style", "hidden": true },
8+
{ "type": "refactor", "hidden": true },
9+
{ "type": "perf", "hidden": true },
10+
{ "type": "test", "hidden": true }
1111
]
1212
}

package.json

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"check-update": "yarn upgrade-interactive --latest"
2929
},
3030
"dependencies": {
31-
"core-js": "^3.20.2",
31+
"core-js": "^3.20.3",
3232
"highlight.js": "^11.4.0",
3333
"i18next": "^21.6.6",
3434
"immer": "^9.0.12",
@@ -46,16 +46,16 @@
4646
"devDependencies": {
4747
"@commitlint/cli": "^16.0.2",
4848
"@commitlint/config-conventional": "^16.0.0",
49-
"@nrwl/cli": "^13.4.4",
50-
"@nrwl/cypress": "^13.4.4",
51-
"@nrwl/eslint-plugin-nx": "^13.4.4",
52-
"@nrwl/jest": "^13.4.4",
53-
"@nrwl/linter": "^13.4.4",
49+
"@nrwl/cli": "^13.4.5",
50+
"@nrwl/cypress": "^13.4.5",
51+
"@nrwl/eslint-plugin-nx": "^13.4.5",
52+
"@nrwl/jest": "^13.4.5",
53+
"@nrwl/linter": "^13.4.5",
5454
"@nrwl/nx-cloud": "13.0.2",
55-
"@nrwl/react": "^13.4.4",
56-
"@nrwl/tao": "^13.4.4",
57-
"@nrwl/web": "^13.4.4",
58-
"@nrwl/workspace": "^13.4.4",
55+
"@nrwl/react": "^13.4.5",
56+
"@nrwl/tao": "^13.4.5",
57+
"@nrwl/web": "^13.4.5",
58+
"@nrwl/workspace": "^13.4.5",
5959
"@testing-library/jest-dom": "^5.16.1",
6060
"@testing-library/react": "13.0.0-alpha.5",
6161
"@testing-library/react-hooks": "^7.0.2",
@@ -71,7 +71,7 @@
7171
"babel-jest": "^27.4.6",
7272
"cypress": "^9.2.1",
7373
"dotenv": "^11.0.0",
74-
"eslint": "^8.6.0",
74+
"eslint": "^8.7.0",
7575
"eslint-config-prettier": "^8.3.0",
7676
"eslint-plugin-cypress": "^2.12.1",
7777
"eslint-plugin-import": "^2.25.4",
@@ -97,7 +97,7 @@
9797
"stylelint-config-standard": "^24.0.0",
9898
"stylelint-order": "^5.0.0",
9999
"stylelint-scss": "^4.1.0",
100-
"ts-jest": "^27.1.2",
100+
"ts-jest": "^27.1.3",
101101
"ts-node": "^10.4.0",
102102
"typescript": "~4.5.2",
103103
"yaml-front-matter": "^4.1.1"

packages/ui/src/components/_select-box/SelectBox.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ export interface DSelectBoxProps extends React.HTMLAttributes<HTMLDivElement> {
1414
dClearIcon?: React.ReactNode;
1515
dSize?: 'smaller' | 'larger';
1616
dPlaceholder?: string;
17+
dContentTitle?: string;
1718
dDisabled?: boolean;
1819
dLoading?: boolean;
1920
onClear?: () => void;
@@ -29,6 +30,7 @@ const SelectBox: React.ForwardRefRenderFunction<HTMLDivElement, DSelectBoxProps>
2930
dClearIcon,
3031
dSize,
3132
dPlaceholder,
33+
dContentTitle,
3234
dDisabled = false,
3335
dLoading = false,
3436
onClear,
@@ -136,7 +138,9 @@ const SelectBox: React.ForwardRefRenderFunction<HTMLDivElement, DSelectBoxProps>
136138
onChange={handleSearchChange}
137139
></input>
138140
) : (
139-
<div className={`${dPrefix}select-box__content`}>{children}</div>
141+
<div className={`${dPrefix}select-box__content`} title={dContentTitle}>
142+
{children}
143+
</div>
140144
)}
141145
<div className={`${dPrefix}select-box__suffix`}>{dSuffix}</div>
142146
{!(dSearchable && dExpanded) && !children && dPlaceholder && (

0 commit comments

Comments
 (0)