-
Notifications
You must be signed in to change notification settings - Fork 186
style(app,protocol-designer,labware-library,opentrons-ai-client): update stylelint #19993
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
base: edge
Are you sure you want to change the base?
Conversation
…ate stylelint to the latest update stylelint to the latest v16.25.0 close AUTH-2455
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## edge #19993 +/- ##
===========================================
+ Coverage 25.09% 56.87% +31.77%
===========================================
Files 3549 3549
Lines 296873 297015 +142
Branches 42169 42400 +231
===========================================
+ Hits 74513 168924 +94411
+ Misses 222337 127818 -94519
- Partials 23 273 +250
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
SyntaxColoring
left a comment
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.
Thank you thank you!
I noticed a handful of weird things.
| container-name: controls-container; | ||
| container-type: inline-size; |
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.
What does this do?
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.
this is to use container-query for protocol visualization.
initially i started working with this branch for protocol viz but stylelint showed errors to those lines because the version we use doesn't support new CSS properties and noticed that the last update was 6 years ago.
i switched the purpose of this branch.
| /* from legacy --button-disabled */ | ||
| font-weight: normal; | ||
| /* from legacy --button-disabled */ | ||
| cursor: default; |
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.
All of the nesting changes in this file are kind of weird, aren't they? What's going on here?
Especially with the redundant lines:
background-color: color-mod(var(--c-bg-dark) tint(10%));
background-color: color-mod(var(--c-bg-dark) tint(5%));
color: var(--c-font-light);
color: var(--c-font-disabled);
|
|
||
| .well_group_title { | ||
| margin-left: -var(--spacing-5); | ||
| margin-left: var(--spacing-5); |
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.
Nice catch.
| --link-btn: {;;; | ||
|
|
||
| display: block;;;; | ||
| width: 100%;;;; | ||
| padding: 1rem;;;; | ||
| border-radius: 3px;;;; | ||
| margin: 1.5rem 0 0.5rem;;;; | ||
| cursor: pointer;;;; | ||
| font-family: AkkoPro-Regular, 'Ropa Sans', 'Open Sans', "sans-serif;"";"";"; | ||
| font-size: var(--fs-body-2);;;; | ||
| text-align: center;;;; |
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.
What's going on with all the semicolons here?
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.
they were added by format-css.
i'll remove them.
| &:hover { | ||
| background-color: var(--c-blue); | ||
| background-color: #00f; | ||
| } | ||
| } | ||
|
|
||
| &:hover { | ||
| background-color: #00f; | ||
| } | ||
| color: white; | ||
| color: white; |
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.
Same question as before. Weird nesting, and redundant property assignments.
| position: relative; | ||
| position: absolute; |
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.
Redundant property assignments again.
In this case, can --aspect be deleted entirely? It looks like --aspect-4-3, --aspect-1-1, and --aspect-item were deleted because nothing used them, but I can't find anything that uses --aspect, either.
| inset: 0; | ||
| } | ||
|
|
||
| /* padding-bottom: 100%; */ |
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.
Leftover comment?
.stylelintrc.js
Outdated
| 'container-name', | ||
| 'container-type', |
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.
Nit: Can we add an empty line to separate these from the group above, so it's clear that the // TODO(mc, 2018-02-09) comment doesn't apply to these?
| 'container-name', | |
| 'container-type', | |
| 'container-name', | |
| 'container-type', |
|
@SyntaxColoring |
…EPS actions (#19976) ## Overview This simplifies some of Protocol Designer's code for deleting steps. Goes towards EXEC-2024. ## Details Depending on how you delete a step in Protocol Designer, it either happens through the `DELETE_STEP` Redux action or the `DELETE_MULTIPLE_STEPS` Redux action. The two actions have grown a small inconsistency between them, having to do with how they update the *selected* step. [`DELETE_MULTIPLE_STEPS` tries to automatically select a new step to replace it](https://github.com/Opentrons/opentrons/blob/4cd4ab98bd7fca0f8912f6d66aa31a0736ea67e1/protocol-designer/src/steplist/actions/actions.ts#L73), whereas [`DELETE_STEP` simply clears the selection](https://github.com/Opentrons/opentrons/blob/58619d35ebf4b59f2e69a4d7503d9ead001b3e42/protocol-designer/src/ui/steps/reducers.ts#L86). The algorithm for automatically selecting a new step would get more complicated with the feature of concurrent module actions, so I'm not sure whether we'll choose to preserve that behavior, or the simpler behavior of clearing the selection. But regardless of which behavior we choose, it's nicer if we don't have to keep two actions in sync with each other. So, this removes the `DELETE_STEP` action. Instead, you can just dispatch `DELETE_MULTIPLE_STEPS` with a 1-element list.
* fix(app): fix unnecessary rendering issue on slideouts
# Overview Having more info about Flex log files in the manual is helpful. Also, and perhaps more important, having this in the Flex manual allows us to get rid of another bad Help Center article ([How to download the logs on Opentrons Flex](https://support.opentrons.com/s/article/How-to-download-the-logs-on-Opentrons-Flex)). For this article, we'll repurpose the intro and file download instructions from the Flex service manual, but without all the extra details used by the service techs. See also RTC-824 Sandbox docs: - Top-level section re-org: https://sandbox.docs.opentrons.com/docs-download-log-files/flex/advanced-operation/ - Log files: https://sandbox.docs.opentrons.com/docs-download-log-files/flex/advanced-operation/log-files/ ## Test Plan and Hands on Testing - Work through the instructions to make sure the steps are correct. - Check to ensure images render. ## Changelog On the surface, a simple change or PR: add steps on log file download. I'd recommend some reorganization. This belongs with the other "advanced" operations articles. I'd like to: - Break up the content in `advanced-operations.md` - Make this section a multi-doc section to now include: - An intro: `advanced-operations/index.md` to summarize the sections. - Make the command line / SSH piece a separate file. - Make the Jupyter Notebook a separate file - Add this log file as a separate file ## Review requests Consider the reorg. Is there another place to put this _without_ changing the structure? ## Risk assessment Low, docs changes only. --------- Co-authored-by: Ed Cormany <[email protected]>
… on the camera tab (#19995)
OT-2 utilizes the `eq` equalizer filter fields instead of the `lut` Look-up-table fields of the Flex
### 8.8 release notes placeholder A little something so we can tell in the app we are upgrading on the 8.8 alpha until the actual notes are ready.
### Fix GitHub Actions Slack notification syntax error
Problem:
GitHub Actions workflows were failing with syntax errors when using the
simple-build-alert action:
Root Cause:
Custom GitHub Actions cannot directly access the secrets context. They
must receive secrets as input parameters.
Solution:
Updated simple-build-alert action to accept webhook_url as an input
parameter
Updated all 6 workflows that use this action to pass the webhook URL:
app-test-build-deploy.yaml
ll-test-build-deploy.yaml
opentrons-ai-production-deploy.yaml
components-test-build-deploy.yaml
pd-test-build-deploy.yaml
shared-data-test-lint-deploy.yaml
Changes:
Added webhook_url input parameter to
.github/actions/simple-build-alert/action.yml
Updated all workflow files to pass webhook_url: ${{
secrets.OT_APP_RELEASE_SLACK_NOTIFICATION_WEBHOOK_URL }} to the action
Result:
Slack notifications for build success/failure/cancellation now work
properly across all deployment workflows.
* update form-data package
# Overview Adds an output of the robots WiFi and Ethernet MAC addresses to the Robot diagnostics QC script. Customers have requested the ability to know the MAC address of their robot before they receive it or set it up. By logging the MAC address in the output of the diagnostic scripts we can now look up the MAC address of a robot based on it's serial number in our production database. ## Test Plan and Hands on Testing Ran the test script on a Flex in the office. Checked that the MAC addresses were contained in the output CSV. ## Changelog Modifies the connectivity section of the flex diagnostics QC script in hardware testing to add wifi and ethernet mac address outputs. ## Review requests ## Risk assessment Minimal only impacts hardware testing code Co-authored-by: Ryan Howard <[email protected]>
<!-- Thanks for taking the time to open a Pull Request (PR)! Please make sure you've read the "Opening Pull Requests" section of our Contributing Guide: https://github.com/Opentrons/opentrons/blob/edge/CONTRIBUTING.md#opening-pull-requests GitHub provides robust markdown to format your PR. Links, diagrams, pictures, and videos along with text formatting make it possible to create a rich and informative PR. For more information on GitHub markdown, see: https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax To ensure your code is reviewed quickly and thoroughly, please fill out the sections below to the best of your ability! --> # Overview reworking the "what's new on Flex" section > "Flex-exclusive features" for a few reasons: - the OT-2 and Flex comparison is no longer what's most important in the introduction. here, I've walked back the comparison text (but still include a small section to do so). - this section can be useful to us to describe what's different/exclusive to Flex without comparison. This can also be a soft landing place for new features that aren't ready for an entire section, but will be one day (like LLD. After 8.8, this could very well get its own section). -also sprinkling throughout: LLD, liquid classes, a mention of liquid classes in QT. Trying to bridge the gap before some of these features get more new shiny things added to them and can have their own section (LLD mostly). <!-- Describe your PR at a high level. State acceptance criteria and how this PR fits into other work. Link issues, PRs, and other relevant resources. --> ## Test Plan and Hands on Testing <!-- Describe your testing of the PR. Emphasize testing not reflected in the code. Attach protocols, logs, screenshots and any other assets that support your testing. --> ## Changelog <!-- List changes introduced by this PR considering future developers and the end user. Give careful thought and clear documentation to breaking changes. --> ## Review requests <!-- - What do you need from reviewers to feel confident this PR is ready to merge? - Ask questions. --> ## Risk assessment <!-- - Indicate the level of attention this PR needs. - Provide context to guide reviewers. - Discuss trade-offs, coupling, and side effects. - Look for the possibility, even if you think it's small, that your change may affect some other part of the system. - For instance, changing return tip behavior may also change the behavior of labware calibration. - How do your unit tests and on hands on testing mitigate this PR's risks and the risk of future regressions? - Especially in high risk PRs, explain how you know your testing is enough. -->
* fix(app-shell): fix protocol file read function issue
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.
Pull Request Overview
This PR updates stylelint from version 11.0.0 to 16.25.0 and stylelint-config-standard from 19.0.0 to 39.0.1. The update enables better CSS validation, including detection of invalid CSS property values and deprecated properties that the older version couldn't catch.
Key changes include:
- Updating deprecated CSS properties (e.g.,
grid-gap→gap,word-wrap→overflow-wrap) - Converting color values from
rgba()to modernrgb()with alpha notation - Replacing deprecated positioning properties with the
insetshorthand - Standardizing
@importstatements to useurl()syntax
Reviewed Changes
Copilot reviewed 72 out of 74 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| package.json | Updates stylelint dependencies to latest versions |
| .stylelintrc.js | Adds expanded ignore patterns and precision configuration |
| Various CSS files across components, app, labware-library, protocol-designer, opentrons-ai-client | Fixes CSS syntax to comply with updated stylelint rules |
| docs/flex/docs/introduction.md | Formatting improvements to markdown table and list structure |
| app-shell/package.json | Updates form-data dependency version |
Comments suppressed due to low confidence (1)
components/src/molecules/WizardHeader/wizardheader.module.css:1
- The perspective value should include a unit. Changed from
1000to1000pxwhich is correct.
/* WizardHeader CSS Module */
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
labware-library/src/components/LabwareDetails/styles.module.css
Outdated
Show resolved
Hide resolved
app/src/organisms/ODD/RunningProtocol/RunFailedModal/runfailedmodal.module.css
Outdated
Show resolved
Hide resolved
...organisms/ODD/RunningProtocol/CurrentRunningProtocolCommand/currentrunningcommand.module.css
Outdated
Show resolved
Hide resolved
….com/Opentrons/opentrons into style_update-stylelint-to-the-latest
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.
Pull Request Overview
Copilot reviewed 72 out of 74 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| background-color: #00f; | ||
| } | ||
| } | ||
| }; |
Copilot
AI
Nov 4, 2025
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.
CSS custom properties (CSS variables) should end with a semicolon, not a closing brace with semicolon. The syntax --link-btn-blue: { ... }; is non-standard CSS. This appears to be attempting to use CSS-in-JS or a preprocessor syntax that may not be valid in standard CSS.
| --spacing-link: 1.75rem; | ||
| --spacing-mobile-heading: 4.5rem; | ||
|
|
||
| --font-menu-title: { |
Copilot
AI
Nov 4, 2025
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.
CSS custom properties cannot contain object-like values with braces. The syntax --font-menu-title: { ... } is invalid in standard CSS. Consider using separate CSS custom properties for each font property or using a CSS preprocessor if this syntax is required.
| container-name: controls-container; | ||
| container-type: inline-size; |
Copilot
AI
Nov 4, 2025
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.
The container query properties were added but there's no visible usage of corresponding @container queries in the diff. Ensure that container queries are actually implemented elsewhere in the codebase to make use of these properties.
Overview
update stylelint to the latest v16.25.0
this will improve our CSS code since lint can catch the following case that the version we use couldn't and we can avoid using deprecated CSS properties and invalid CSS property values.
The changes I needed are in this doc.
close AUTH-2455
Test Plan and Hands on Testing
Changelog
Review requests
Risk assessment