-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(HMS-3574): add script to search compliant components
This change add two helper scripts, one to locate ouiaId compliant components places; the other one where ouiaId is used. See: https://www.patternfly.org/developer-resources/open-ui-automation/#ouia-compliant-patternfly-5-components As migration to PF5 is coming, we have added the reference the PF5 compliant components. The script match the list from the above link. Co-authored-by: Akshay Adhikari <[email protected]> Signed-off-by: Alejandro Visiedo <[email protected]>
- Loading branch information
Showing
2 changed files
with
54 additions
and
0 deletions.
There are no files selected for viewing
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,39 @@ | ||
#!/bin/bash | ||
|
||
# See: https://www.patternfly.org/developer-resources/open-ui-automation/#ouia-compliant-patternfly-5-components | ||
# See: https://github.com/podengo-project/idmsvc-frontend/pull/28 | ||
|
||
opts=(-HRn) | ||
|
||
# react-core package # Prefix to use on ouiaId attribute | ||
opts+=(-e \<Alert) # Alert | ||
opts+=(-e \<Breadcrumb) # Breadcrumb | ||
opts+=(-e \<Button) # Button|Link | ||
opts+=(-e \<Card) # Card | ||
opts+=(-e \<Checkbox) # Checkbox | ||
opts+=(-e \<Chip) # Chip | ||
opts+=(-e \<Dropdown) # Dropdown | ||
opts+=(-e \<DropdownItem) # Dropitem | ||
opts+=(-e \<FormSelect) # Select | ||
opts+=(-e \<Menu) # Menu | ||
opts+=(-e \<Modal) # Modal | ||
opts+=(-e \<Navigation) # Nav | ||
opts+=(-e \<NavExpandable) # Navexpandable | ||
opts+=(-e \<NavItem) # Navitem | ||
opts+=(-e \<Pagination) # Pagination | ||
opts+=(-e \<Radio) # Radio | ||
opts+=(-e \<Select) # Select | ||
opts+=(-e \<Switch) # Switch | ||
opts+=(-e \<TabContent) # Tabcontent | ||
opts+=(-e \<Tabs) # Tabs | ||
opts+=(-e \<Text) # Text | ||
opts+=(-e \<TextInput) # Textinput | ||
opts+=(-e \<Title) # Title | ||
opts+=(-e \<Toolbar) # Toolbar | ||
|
||
# react-table package | ||
opts+=(-e \<Table) # Table | ||
opts+=(-e \<Tr) # Tr | ||
|
||
# Launch the search | ||
grep "${opts[@]}" src/ |
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,15 @@ | ||
#!/bin/bash | ||
|
||
# Quick script to collect all the places where the ouiaId | ||
# is used (for compliant components), and directly used | ||
# data-ouia-component-id attribute (expanded for the compliant | ||
# components), to wrap the no compliant components that we | ||
# want to select by ouiaId | ||
|
||
opts=() | ||
|
||
opts+=(-e ouiaId) | ||
opts+=(-e data-ouia-component-id) | ||
|
||
grep -HRn "${opts[@]}" src/ | ||
|