Skip to content
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

feat: remove deprecated code issues #133 #137

Merged
merged 1 commit into from
Jan 3, 2025

Conversation

blackfalcon
Copy link
Member

@blackfalcon blackfalcon commented Jan 1, 2025

Alaska Airlines Pull Request

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Resolves: #133

Summary:

  • Resolved Issues with Deprecated Features

    • Removed the fixed attribute.
    • Eliminated legacy size options (xxxs to xxxl).
    • Simplified margin handling to numeric values (none, 25, 50, etc.).
  • Codebase Cleanup

    • Removed legacy utility classes and pixel-based rendering styles.
    • Deleted outdated examples from documentation and API.
  • .husky/pre-commit Fixes

    • Removed the following lines that would fail in version v10.0.0:
      #!/usr/bin/env sh
      . "$(dirname -- "$0")/_/husky.sh"
  • Documentation and Dependencies Updates

    • Revised documentation files and examples for the updated implementation.
    • Updated package.json dependencies to the latest @aurodesignsystem/auro-library version.
  • Benefits of These Changes

    • Streamlined codebase for improved maintainability.
    • Removed outdated functionality to align with modern practices.
    • Ensured compatibility with future versions of the tools and frameworks.

On branch dsande/deprecatedFeats/#133
Changes to be committed:
modified: .husky/pre-commit
deleted: apiExamples/fixed.html
modified: apiExamples/margins.html
modified: apiExamples/margins2.html
modified: demo/api.md
modified: demo/index.min.js
modified: docs/api.md
modified: docs/partials/api.md
modified: package-lock.json
modified: package.json
modified: src/auro-header.js
modified: src/style.scss
modified: test/auro-header.test.js

Type of change:

Please delete options that are not relevant.

  • New capability
  • Revision of an existing capability
  • Infrastructure change (automation, etc.)
  • Other (please elaborate)

Checklist:

  • My update follows the CONTRIBUTING guidelines of this project
  • I have performed a self-review of my own update

By submitting this Pull Request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Pull Requests will be evaluated by their quality of update and whether it is consistent with the goals and values of this project. Any submission is to be considered a conversation between the submitter and the maintainers of this project and may require changes to your submission.

Thank you for your submission!

-- Auro Design System Team

Summary by Sourcery

Documentation:

  • Update documentation to reflect the removal of deprecated features and the new margin handling.

@blackfalcon blackfalcon requested a review from a team as a code owner January 1, 2025 00:21
@blackfalcon blackfalcon self-assigned this Jan 1, 2025
Copy link

sourcery-ai bot commented Jan 1, 2025

Reviewer's Guide by Sourcery

This PR removes deprecated code and updates dependencies. It streamlines the codebase by removing the "fixed" attribute, legacy size options, pixel-based rendering styles, and simplifying margin handling to numeric values. Additionally, it cleans up documentation, API examples, and resolves issues with the .husky/pre-commit file. Finally, it updates the package.json dependencies to the latest @aurodesignsystem/auro-library version.

Class diagram showing removed attributes and properties from auro-header

classDiagram
    class AuroHeader {
        -removed fixed: Boolean
        -removed type: String
        +display: String
        +level: String
        +margin: String
        +size: String
        +spacingDecision(size)
        +spacingApplied(size)
    }
    note for AuroHeader "Removed deprecated 'fixed' and 'type' attributes.
Simplified size options to numeric values only."
Loading

State diagram showing margin size value changes

stateDiagram-v2
    [*] --> MarginSizes
    MarginSizes --> Removed: Legacy sizes
    MarginSizes --> Kept: Numeric sizes
    Removed: xxxs
    Removed: xxs
    Removed: xs
    Removed: sm
    Removed: md
    Removed: lg
    Removed: xl
    Removed: xxl
    Removed: xxxl
    Kept: none
    Kept: 25
    Kept: 50
    Kept: 100
    Kept: 150
    Kept: 200
    Kept: 300
    Kept: 400
    Kept: 600
    Kept: 800
Loading

File-Level Changes

Change Details Files
Removed deprecated fixed attribute and legacy size options.
  • Removed support for the fixed attribute and pixel-based rendering styles.
  • Removed legacy size options (xxxs to xxxl) for margin adjustments.
  • Simplified margin handling to use numeric values only.
  • Updated tests to reflect changes in size options.
  • Removed references to fixed and legacy size options in documentation and API examples.
src/auro-header.js
src/style.scss
test/auro-header.test.js
demo/api.md
docs/api.md
docs/partials/api.md
Removed deprecated utility classes and pixel-based rendering styles.
  • Deleted legacy utility classes related to pixel-based rendering and fixed attribute.
  • Removed pixel-based rendering styles from the SCSS file.
src/style.scss
Fixed .husky/pre-commit issues.
  • Removed problematic lines from the pre-commit file that caused failures in v10.0.0.
.husky/pre-commit
Updated documentation and dependencies.
  • Revised documentation files and API examples to reflect the updated implementation.
  • Updated package.json to use the latest version of @aurodesignsystem/auro-library.
  • Regenerated package-lock.json to reflect dependency changes.
  • Updated demo files to align with code changes.
demo/api.md
demo/index.min.js
docs/api.md
docs/partials/api.md
package.json
package-lock.json
Removed outdated API examples.
  • Deleted the fixed.html file from API examples as it is no longer relevant.
apiExamples/fixed.html
Updated margin handling in API examples.
  • Updated margin handling in example files to use numeric values.
  • Removed unnecessary utility classes from example HTML.
apiExamples/margins.html
apiExamples/margins2.html

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time. You can also use
    this command to specify where the summary should be inserted.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

github-actions bot commented Jan 1, 2025

Surge demo deployment failed! 😭

@blackfalcon
Copy link
Member Author

NOTE: in order to update API docs, I temp added back in the code needed to make that work. See following issue:

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @blackfalcon - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider removing the remaining className attributes in the examples to match the implementation changes where they were removed
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

BREAKING CHANGE: This code update resolves issues with deprecated features and cleans up
the implementation of the `auro-header` component. The `fixed` attribute and legacy size
options (`xxxs` to `xxxl`) have been eliminated, along with related utility classes and
documentation references, simplifying margin handling to specified numeric
values (`none`, `25`, `50`, etc.).

Legacy styles and examples supporting pixel-based rendering are removed, aligning the
component with modern practices. Additionally, two lines in `.husky/pre-commit` that would
fail in version `v10.0.0`—`#!/usr/bin/env sh` and `. "$(dirname -- "$0")/_/husky.sh"`—were
removed to ensure compatibility.

Updates include revisions to documentation files, API examples, and the `auro-header.js` source code,
while dependencies in the `package.json` file are updated, reflecting the latest version of
`@aurodesignsystem/auro-library`. These changes streamline the codebase, remove outdated
functionality, and improve maintainability for future development.

On branch dsande/deprecatedFeats/#133
Changes to be committed:
modified:   .husky/pre-commit
deleted:    apiExamples/fixed.html
modified:   apiExamples/margins.html
modified:   apiExamples/margins2.html
modified:   demo/api.md
modified:   demo/index.min.js
modified:   docs/api.md
modified:   docs/partials/api.md
modified:   package-lock.json
modified:   package.json
modified:   src/auro-header.js
modified:   src/style.scss
modified:   test/auro-header.test.js
@jason-capsule42 jason-capsule42 force-pushed the dsande/deprecatedFeats/#133 branch from b6e637e to 03d1d0a Compare January 3, 2025 19:04
@jason-capsule42 jason-capsule42 merged commit e52bfe1 into main Jan 3, 2025
6 of 7 checks passed
@jason-capsule42 jason-capsule42 deleted the dsande/deprecatedFeats/#133 branch January 3, 2025 19:06
@blackfalcon
Copy link
Member Author

🎉 This PR is included in version 3.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@blackfalcon blackfalcon added the released Completed work has been released label Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
released Completed work has been released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multiple issues with deprecated features and case sensitive selectors
2 participants