@dhasdk/simple-ui 1.0.14 → 1.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1325,8 +1325,11 @@ Full list of props below
1325
1325
  | ----------- | -------- | -------- | -------- | ----------- |
1326
1326
  | airaLabel | **`string`** | Yes | **`'Search'`** | The aria-label to assign to this Search component |
1327
1327
  | className | **`string`** | Yes | see (1) below | alternate css classes to add/change styling of the div that wraps the input element. |
1328
+ | classNameContainer | **`string`** | Yes | **`h-12 md:h-[50px] lg:h-14 flex items-center relative`** | alternate css classes to add/change styling of the span tag that wraps the search component. |
1329
+ | classNameInputContainer | **`string`** | Yes | **`border-[#6a686b] w-[309px] md:w-[334px] lg:w-[350px] inline-flex bg-white items-center`** | alternate css classes to add/change styling of the span tag that wraps the search component. |
1328
1330
  | iconLink | **`boolean`** | Yes | **`{false}`** | If set to true, a search icon is displayed that when clicked will expand into a wider Search component. |
1329
1331
  | searchableData | **`SearchDataItem[]`** | No | undefined | The data that the search component uses as its data source. This data must conform to the SearchDataItem interface. An example data file is shown above. |
1332
+ | searchHint | **`string`** | Yes | **`"Search result"`** | Changes the default input element hint text |
1330
1333
  | setSearchResults | **`(DataSearchResults) => return void`** | Yes |undefined | If the use case entails sending the user to a separate results page, provide a function here that takes those search and performs the desired action. See (2) below for the DataSearchResults definition. |
1331
1334
 
1332
1335
  1. Default className
@@ -1400,6 +1403,16 @@ The Search Results Interface
1400
1403
  }
1401
1404
  ```
1402
1405
 
1406
+ Example **`classNameContainer`** and **`classNameInputContainer`** usage:
1407
+
1408
+ ```jsx
1409
+ <Search
1410
+ searchableData={SearchableData}
1411
+ classNameContainer='w-full'
1412
+ classNameInputContainer="w-full md:w-full lg:w-full"
1413
+ />
1414
+ ```
1415
+
1403
1416
  ### Dependencies
1404
1417
 
1405
1418
  **_none_**
@@ -1648,6 +1661,7 @@ Full list of props below
1648
1661
  | Prop | Type | Optional | Default | Description |
1649
1662
  | ----------- | -------- | -------- | -------- | ----------- |
1650
1663
  | appName | string | No | undefined | The application name to dispilay |
1664
+ | children | ReactNode | Yes | undefined | This prop takes in any children and displays them between the horizontal rule and the list of menu items. It is intended for to allow developers to add a Search component. See usage example above. |
1651
1665
  | className | string | Yes | (1) below | a group of alternate css classes that can be specified by the developer and applied to the outer **`div`** element. |
1652
1666
  | clickOutsideCloses | boolean | Yes | **`false`** | clicking or tapping elsewhere on the application will close the SideBarNav |
1653
1667
  | image | string | No | undefined | string path to the application logo to display |
@@ -1712,7 +1726,11 @@ const menuItems = [
1712
1726
  clickOutsideCloses
1713
1727
  menu
1714
1728
  className='bg-slate-200 border border-slate-400 rounded-l-md h-full'
1715
- />
1729
+ >
1730
+ <div className="my-4">
1731
+ <Search searchableData={SearchableData} />
1732
+ </div>
1733
+ </SideBarNav>
1716
1734
  ```
1717
1735
 
1718
1736
  ### Dependencies