-
Notifications
You must be signed in to change notification settings - Fork 273
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(theme): [button-group] refactor button-group theme vars #2276
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ test('测试按钮默认插槽', async ({ page }) => { | |
await page.goto('button-group#slot-default') | ||
const demo = page.locator('#slot-default') | ||
const buttonGroup = demo.locator('.tiny-button-group').first() | ||
await expect(buttonGroup.getByRole('button', { name: 'Button1' })).toHaveCSS('background-color', 'rgb(94, 124, 224)') | ||
await expect(buttonGroup.getByRole('button', { name: 'Button2' })).toHaveCSS('background-color', 'rgb(80, 212, 171)') | ||
await expect(buttonGroup.getByRole('button', { name: 'Button1' })).toHaveCSS('background-color', 'rgb(25, 25, 25)') | ||
await expect(buttonGroup.getByRole('button', { name: 'Button2' })).toHaveCSS('background-color', 'rgb(92, 179, 0)') | ||
Comment on lines
+8
to
+9
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Codebase verification Outdated color values found in multiple files. The shell script detected several instances of the old color values
These findings indicate that the color scheme updates are not consistently applied across the project. Please ensure that all instances of the old colors are updated to maintain design consistency and adhere to accessibility standards. 🔗 Analysis chainVerify the new color scheme for buttons. The background colors for 'Button1' and 'Button2' have been updated to Please confirm that:
You may want to run the following command to check for any other occurrences of the old color values: 🏁 Scripts executedThe following scripts were executed for the analysis: Script: #!/bin/bash
# Search for old color values in all files
rg -i 'rgb\(94,\s*124,\s*224\)|rgb\(80,\s*212,\s*171\)' --type css --type less --type scss --type js --type ts
Length of output: 141 Script: #!/bin/bash
# Search for old color values in all files with corrected file types
rg -i 'rgb\(94,\s*124,\s*224\)|rgb\(80,\s*212,\s*171\)' --type css --type less --type sass --type js --type ts
Length of output: 3343 |
||
await expect(buttonGroup.getByRole('button', { name: 'Button3' })).toHaveClass(/is-disabled/) | ||
}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codebase verification
Inconsistent Color Value Usage Detected
The background color for Button3 has been updated to
rgb(20, 118, 255)
inexamples/sites/demos/pc/app/button-group/basic-usage.spec.ts
. However, the old color valuergb(94, 124, 224)
is still present in multiple locations across the codebase, which may lead to inconsistencies in the UI.Affected Files with Old Color (
rgb(94, 124, 224)
):examples/sites/demos/pc/app/wizard/base-usage.spec.ts
examples/sites/demos/pc/app/wizard/vertical.spec.ts
examples/sites/demos/pc/app/time-line/status.spec.ts
examples/sites/demos/pc/app/tabs/basic-usage.spec.ts
examples/sites/demos/pc/app/tag-group/tag-group-effect.spec.js
examples/sites/demos/pc/app/base-select/automatic-dropdown.spec.ts
examples/sites/demos/pc/app/link/link-style.spec.ts
examples/sites/demos/pc/app/checkbox/checkbox-slot.spec.ts
examples/sites/demos/pc/app/cascader-panel/basic-usage.spec.ts
examples/sites/demos/pc/app/bulletin-board/base.spec.ts
examples/sites/demos/pc/app/bulletin-board/active-name.spec.ts
packages/theme/src/theme/devui-theme-map.js
Affected Files with New Color (
rgb(20, 118, 255)
):examples/sites/demos/pc/app/switch/basic-usage.spec.ts
examples/sites/demos/pc/app/radio/basic-usage.spec.ts
examples/sites/demos/pc/app/checkbox/checkbox-button.spec.ts
examples/sites/demos/pc/app/checkbox/basic-usage.spec.ts
examples/sites/demos/pc/app/button-group/disabled.spec.ts
examples/sites/demos/pc/app/button-group/basic-usage.spec.ts
examples/sites/demos/pc/app/button/ghost.spec.ts
examples/sites/demos/pc/app/button/text.spec.ts
examples/sites/demos/pc/app/badge/type.spec.ts
examples/sites/demos/mobile/app/alert/basic-usage.spec.ts
Please verify whether the remaining instances of the old color should also be updated to ensure a consistent theme throughout the project.
🔗 Analysis chain
Verify the updated background color value.
The expected background color for Button3 has been changed from
rgb(94, 124, 224)
torgb(20, 118, 255)
. This change likely reflects an update in the component's design or theme.To ensure this change is consistent across the codebase, please run the following script:
This will help identify if the color change has been consistently applied across the project.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 2916
Script:
Length of output: 4845