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(core/dropdown-button): add dropdown-button #229

Merged
merged 12 commits into from
Jan 11, 2023

Conversation

goncalosard
Copy link
Contributor

Pull request checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)
  • Build (yarn build) was run locally and any changes were pushed
  • Unit tests (yarn test) were run locally and passed
  • Visual Regression Tests (yarn visual-regression) were run locally and passed
  • Linting (npm lint) was run locally and passed

Pull request type

Please check the type of change your PR introduces:

  • Bug fix
  • Feature
  • Refactoring (no functional changes, no API changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the new behavior?

Implemented new component dropdown-button as requested in #173

image

A new prop in icon-button was also implemented to let the small triangle to be toggle when its used on a dropdown-button.

Build is not passing because of the problem that i'm Windows, so the file component-doc.json needs to be re-commited by someone with mac.

Visual-regression tests for this new component are created, but it is needed to check if any onther tests are failing and the new
snapshots need to be commited.

Code used for testing

    <ix-dropdown-button
      label="Dropdown"
      variant="Primary"
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label="Dropdown"
      variant="Primary"
      outline
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label="Dropdown"
      variant="Primary"
      ghost
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label="Dropdown"
      variant="Primary"
      disabled
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label=""
      variant="Primary"
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label=""
      variant="Primary"
      outline
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label=""
      variant="Primary"
      ghost
      icon="checkboxes"
    ></ix-dropdown-button>
    <ix-dropdown-button
      label=""
      variant="Primary"
      disabled
      icon="checkboxes"
    ></ix-dropdown-button>

Testing

Tested locally

@goncalosard goncalosard linked an issue Dec 7, 2022 that may be closed by this pull request
Copy link
Collaborator

@danielleroux danielleroux left a comment

Choose a reason for hiding this comment

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

  • documentation is missing
  • angular (angular-test-app/preview-examples) examples are missing
  • react (react-test-app/preview-examples) examples are missing
  • html (html-test-app/preview-examples) examples are missing

@danielleroux danielleroux changed the title Feature/button dropdown feat(core/dropdown-button): add dropdown-button Dec 12, 2022
Copy link
Collaborator

@danielleroux danielleroux left a comment

Choose a reason for hiding this comment

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

  • DropdownButton should also provide a possiblity to open a dropdown e.g.
<ix-dropdown-button>
  <ix-dropdown-item></ix-dropdown-item>
  <ix-dropdown-item></ix-dropdown-item>
  ....
</ix-dropdown-button>

See ix-select

@danielleroux danielleroux added this to the 1.2.0 milestone Dec 12, 2022
@danielleroux danielleroux modified the milestones: 1.2.0, next-release Dec 12, 2022
@goncalosard
Copy link
Contributor Author

@danielleroux
Last commit fixed the requests you made(css, triangle, dropdown). Added documentation and examples.
Triangle color is not correct, it cannot inherit, so a variable is needed to match the colors of the icons with the triangle.

@danielleroux
Copy link
Collaborator

@goncalosard

  • Please merge with latest main the branch looks stale to me
  • After merge with latest you must adapt the documentation regarding the playground component (see other docs e.g. buttons.md)
  • Dropdown without icon looks broken

image

@danielleroux danielleroux added the pull request affects minor version The pull request affects only minor version label Dec 19, 2022
@goncalosard
Copy link
Contributor Author

@goncalosard

  • Please merge with latest main the branch looks stale to me
  • After merge with latest you must adapt the documentation regarding the playground component (see other docs e.g. buttons.md)
  • Dropdown without icon looks broken
image

@danielleroux

Added all the requests you made. Please check if its ok.

Build failed because component-doc.json, add your file.

Copy link
Collaborator

@danielleroux danielleroux left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Collaborator

@nuke-ellington nuke-ellington left a comment

Choose a reason for hiding this comment

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

lgtm

@danielleroux danielleroux merged commit 8d6ae8b into main Jan 11, 2023
@danielleroux danielleroux deleted the feature/button-dropdown branch January 11, 2023 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pull request affects minor version The pull request affects only minor version type: enhancement New feature or request
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

implement dropdown-button
3 participants