[Menu] Progress Bars - ox_lib PR 166 (#78)

* Update menu.md

* Update menu.md

* Update context.md

* Update context.md
This commit is contained in:
ItsANoBrainer authored and GitHub committed 2022-12-04 22:41:10 +01:00
1 parent 35b0cf739e
commit af697ebafe
2 files changed
+10

No files matched your search

+6
View File
@@ -51,6 +51,11 @@ lib.registerContext(context)
* FontAwesome icon that will be displayed on the left side, works the same as notification and textui icons.
* iconColor?: `string`
* Colour of the displayed icon.
* progress?: `number`
* Adds a progress bar filled to this percentage
* colorScheme?: `string`
* Sets the color scheme of the progress bar. Current options available are:
* `whiteAlpha`, `blackAlpha`, `gray`, `red`, `orange`, `yellow`, `green`, `teal`, `blue`, `cyan`, `purple`, `pink`
* arrow?: `boolean`
* Shows an arrow on the right side like `menu` does, useful when you are opening a menu from an event. Can be set to false to hide it.
* description?: `string`
@@ -335,3 +340,4 @@ with the `lib.showContext` function, passing in the menu's id.
![menu_example](https://i.imgur.com/aJu92dv.png)
![metadata](https://i.imgur.com/kFGSlBF.png)
![event_menu](https://i.imgur.com/r0Ln4VP.png)
![example](https://i.imgur.com/dUsil3p.png)
+4
View File
@@ -32,7 +32,10 @@ lib.registerMenu(data, cb)
* title: `string`
* options: `table` (`array`)
* label: `string`
* progress?: `number`
* colorScheme?: `string`
* icon?: `string`
* iconColor?: `string`
* values?: `table` (`Array<string | {label: string; description: string}>`)
* If provided creates a side scrollabel list.
* When using object and setting description, the set description will be displayed in the menu tooltip.
@@ -294,3 +297,4 @@ RegisterCommand('testmenu', () => {
</Tabs>
![Example](https://i.imgur.com/eIdWZ4c.png)
![Example2](https://i.imgur.com/GxNetwe.png)