-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1427 from dhis2/menu-item-suffix
feat: menu item suffix
- Loading branch information
Showing
8 changed files
with
68 additions
and
2 deletions.
There are no files selected for viewing
5 changes: 5 additions & 0 deletions
5
components/menu/src/menu-item/features/accepts_suffix.feature
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Feature: The MenuItem accepts a suffix prop | ||
|
||
Scenario: MenuItem renders supplied suffix | ||
Given a MenuItem supplied with a suffix is rendered | ||
Then the suffix will be visible |
10 changes: 10 additions & 0 deletions
10
components/menu/src/menu-item/features/accepts_suffix/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { Given, Then } from 'cypress-cucumber-preprocessor/steps' | ||
|
||
Given('a MenuItem supplied with a suffix is rendered', () => { | ||
cy.visitStory('MenuItem', 'With Suffix') | ||
cy.get('[data-test="dhis2-uicore-menuitem"]').should('be.visible') | ||
}) | ||
|
||
Then('the suffix will be visible', () => { | ||
cy.contains('Suffix').should('be.visible') | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -248,3 +248,6 @@ footer { | |
flex-direction: column; | ||
gap: 8px; | ||
} | ||
.demo-fullwidth { | ||
width: 100%; | ||
} |