import{p as g,q as k}from"./registerWidgets.6f5be576.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="de104103-fef4-49c9-af20-cc7e3df3b3b6",e._sentryDebugIdIdentifier="sentry-dbid-de104103-fef4-49c9-af20-cc7e3df3b3b6")}catch{}})();const w={"cards-input":{name:"Card display",description:"Read a text value from the user simple text input",type:"cards-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]},{key:"card-click",description:"Function or expression to be run when a card is clicked",payloadSchema:[{key:"card",typeName:"Object",description:"The card that was clicked"}]}],dashProperties:{minWidth:200,minHeight:200,initialWidth:400,initialHeight:350},pythonAPI:{name:"read_cards",params:[{argName:"label",description:"The text related to this input",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Card Title"'},{argName:"options",description:"List of dicts representing the cards, each dict can have the following keys: title, subtitle, image, description, topLeftExtra, topRightExtra",typeName:"list",typeDescription:["list[{'title': str, 'subtitle': str, 'image': str, 'description': str, 'topLeftExtra': str, 'topRightExtra': str}]"],isKwarg:!1,default:"None",dashesInitialValue:`[
          {
            "title": "Option 1",
            "subtitle": "Subtitle 1",
            "image": "https://upload.wikimedia.org/wikipedia/commons/thumb/6/6a/Mona_Lisa.jpg/396px-Mona_Lisa.jpg",
            "description": "option 1 description",
            "topLeftExtra": "Left 1",
            "topRightExtra": "Right 1",
          }
        ]`},{argName:"multiple",description:"Whether the user can select multiple options. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"initial_value",description:"The initial value to display to the user. Defaults to None.",typeName:"list",typeDescription:["list[AbstraCard]"],isKwarg:!0,default:"None",formOnly:!0},{argName:"searchable",description:"Whether to show a search bar. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"layout",description:"Whether the cards layout should be 'list' or 'grid'. Defaults to 'list'. The 'grid' only applies to desktop resolutions.",typeName:"str",typeDescription:["str ('list', 'grid')"],isKwarg:!0,default:"'list'"},{argName:"columns",typeName:"int",description:"When layout is 'grid', how many columns to display",isKwarg:!0,default:"2"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Union[list, any]",typeDescription:"The options/option selected by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"options",typeName:"array",items:{typeName:"object",properties:[{argName:"title",typeName:"string",description:""},{argName:"subtitle",typeName:"string",description:""},{argName:"image",typeName:"string",description:""},{argName:"description",typeName:"string",description:""},{argName:"topLeftExtra",typeName:"string",description:""},{argName:"topRightExtra",typeName:"string",description:""}]}},{argName:"multiple",typeName:"boolean"},{argName:"searchable",typeName:"boolean"},{argName:"value",typeName:"array",default:[],items:{typeName:"object",properties:[{argName:"title",typeName:"string",description:""},{argName:"subtitle",typeName:"string",description:""},{argName:"image",typeName:"string",description:""},{argName:"description",typeName:"string",description:""},{argName:"topLeftExtra",typeName:"string",description:""},{argName:"topRightExtra",typeName:"string",description:""}]}},{argName:"layout",typeName:"string",oneOf:["list","grid"]},{argName:"columns",typeName:"number"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Choose your character",options:[{title:"Bulbasaur",subtitle:"Grass / Poison",image:"https://assets.pokemon.com/assets/cms2/img/pokedex/full/001.png",description:"There is a plant seed on its back right from the day this Pok\xE9mon is born. The seed slowly grows larger.",topLeftExtra:"N\xBA",topRightExtra:"001"},{title:"Charmander",subtitle:"Fire",image:"https://assets.pokemon.com/assets/cms2/img/pokedex/full/004.png",description:"It has a preference for hot things. When it rains, steam is said to spout from the tip of its tail.",topLeftExtra:"N\xBA",topRightExtra:"004"},{title:"Squirtle",subtitle:"Water",image:"https://assets.pokemon.com/assets/cms2/img/pokedex/full/007.png",description:"When it retracts its long neck into its shell, it squirts out water with vigorous force.",topLeftExtra:"N\xBA",topRightExtra:"007"}]},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_cards",key:"example1",code:`from abstra.forms import read_cards

card = read_cards(
    "Choose your character",
    [
        {
            "title": "Bulbasaur",
            "subtitle": "Grass / Poison",
            "image": "https://assets.pokemon.com/assets/cms2/img/pokedex/full/001.png",
            "description": "There is a plant seed on its back right from the day this Pok\xE9mon is born. The seed slowly grows larger.",
            "topLeftExtra": "N\xBA",
            "topRightExtra": "001",
        },
        {
            "title": "Charmander",
            "subtitle": "Fire",
            "image": "https://assets.pokemon.com/assets/cms2/img/pokedex/full/004.png",
            "description": "It has a preference for hot things. When it rains, steam is said to spout from the tip of its tail.",
            "topLeftExtra": "N\xBA",
            "topRightExtra": "004",
        },
        {
            "title": "Squirtle",
            "subtitle": "Water",
            "image": "https://assets.pokemon.com/assets/cms2/img/pokedex/full/007.png",
            "description": "When it retracts its long neck into its shell, it squirts out water with vigorous force.",
            "topLeftExtra": "N\xBA",
            "topRightExtra": "007",
        },
    ],
)
# card = { 'title': ..., 'subtitle': ..., 'image': ..., 'description': ..., 'topLeftExtra': ..., 'topRightExtra': ... }
`}]},"checkbox-input":{name:"Checkbox",description:"Allow users to select an option by interacting with a checkbox",type:"checkbox-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:60,minHeight:32,initialWidth:222,initialHeight:32},pythonAPI:{name:"read_checkbox",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Choose your option"'},{argName:"initial_value",description:"The initial value to display to the user.",typeName:"str",isKwarg:!0,default:"False",formOnly:!0},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"bool",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"boolean",items:{typeName:["string","number"]},default:!1},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"I have read and agree to the terms of services"},name:"Basic Example",description:"Basic use of read_checkbox",key:"example1",code:`from abstra.forms import read_checkbox

ans = read_checkbox("I have read and agree to the terms of services")

print(ans)
`},{props:{label:"Would you like to receive product updates and announcements via email?"},name:"Optional field",description:"If check the box is optional, pass the optional parameter required",key:"example2",code:`from abstra.forms import read_checkbox

ans = read_checkbox(
    "Would you like to receive product updates and announcements via email?",
    required=False,
)

print(ans)
`},{props:{label:"I have read and agree to the [terms of services](https://example.com)"},name:"Use markdown to customize label",description:"Use markdown syntax to customize the label",key:"example3",code:`from abstra.forms import read_checkbox

ans = read_checkbox(
    "I have read and agree to the [terms of services](https://example.com)"
)
`}]},"checklist-input":{name:"Checklist",description:"Show a checklist for users to select items",type:"checklist-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:60,minHeight:32,initialWidth:222,initialHeight:112},pythonAPI:{name:"read_checklist",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Choose your option"'},{argName:"options",description:"The options to display to the user, eg. ['Option 1', 'Option 2'] or [{'label': 'Option 1', 'value': '1'}, {'label': 'Option 2', 'value': '2'}]",typeName:"list",typeDescription:["list[AbstraOption]"],isKwarg:!1,default:"None",dashesInitialValue:`[
    {
      "label": "Option 1",
      "value": 1,
    },
    {
      "label": "Option 2",
      "value": 2,
    },
  ]`},{argName:"initial_value",description:"The initial value to display to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None",formOnly:!0},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"List[str]",typeDescription:"The selected values"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"array",items:{typeName:["string","number"]},default:[]},{argName:"options",typeName:"array",items:{typeName:["string","object"],properties:[{argName:"key",typeName:"string",description:"The key of the option on the returning object"},{argName:"value",typeName:"object",description:"The value of the option on the returning object"}]}},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Which programming language have you worked with?",options:["Python","JavaScript","Go","Elixir","Haskell"]},name:"Basic Example",description:"Basic use of read_checklist",key:"example1",code:`from abstra.forms import read_checklist

ans = read_checklist(
    "Which programming language have you worked with?",
    ["Python", "JavaScript", "Go", "Elixir", "Haskell"],
)
`},{props:{label:"What are the solutions to the equation x^2 + 3x + 2 = 0?",options:[{label:"-1",value:"a"},{label:"-2",value:"b"},{label:"0 and -1",value:"c"},{label:"0 and 1",value:"d"},{label:"None of the above",value:"e"}]},name:"Label and value dict",description:"Use a dictionary to specify the label and value of each option. The label will be displayed to the user, and the value will be returned by the widget.",key:"example2",code:`from abstra.forms import read_checklist

ans = read_checklist(
    "What are the solutions to the equation x^2 + 3x + 2 = 0?",
    [
        {"label": "-1", "value": "a"},
        {"label": "-2", "value": "b"},
        {"label": "0 and -1", "value": "c"},
        {"label": "0 and 1", "value": "d"},
        {"label": "None of the above", "value": "e"},
    ],
)

# ans = ["a", "b"]
`},{props:{label:"",options:[{label:"I have read and agree to the [terms of services](https://example.com)",value:"agree"}]},name:"Use markdown in options",description:"Use markdown syntax to customize the options.",key:"example3",code:`from abstra.forms import read_checklist

ans = read_checklist(
    "",
    [
        {
            "label": "I have read and agree to the [terms of services](https://example.com)",
            "value": "agree",
        },
    ],
)
`}]},"click-input":{name:"Button",description:"Buttons allow users to trigger actions.",type:"click-input",autoHeight:!0,events:[{key:"click",description:"Function or expression to be run when the button is clicked",payloadSchema:[]}],dashOnly:!0,dashProperties:{minWidth:60,minHeight:62,initialWidth:140,initialHeight:62},pythonAPI:{name:"read_click",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Click here!"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"None",typeDescription:""}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"}]},examples:[{props:{label:"Send"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_click",key:"example1",code:""}]},"cnpj-input":{name:"CNPJ input",description:"Allow users to insert a CNPJ number into the app.",type:"cnpj-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:222,minHeight:70,initialWidth:222,initialHeight:112},pythonAPI:{name:"read_cnpj",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Insert your CNPJ here!"'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to None.",typeName:"str",typeDescription:["str (00.000.000/0001-00)"],isKwarg:!0,default:"None",formOnly:!0},{argName:"invalid_message",description:"The message to display when the user enters an invalid value. Defaults to None.",typeName:"str",isKwarg:!0,default:"None",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "00.000.000/0001-00".',typeName:"str",typeDescription:["str (00.000.000/0001-00)"],isKwarg:!0,default:'"00.000.000/0001-00"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"invalidMessage",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"Insert your CNPJ below"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_cnpj",key:"example1",code:`from abstra.forms import read_cnpj

name = read_cnpj("Insert your CNPJ below")
`}]},"code-input":{name:"Code input",description:"Code input allow users to insert code and reads it.",type:"code-input",autoHeight:!1,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:377,minHeight:552,initialWidth:377,initialHeight:552},pythonAPI:{name:"read_code",params:[{argName:"label",description:"The label to display to the user",default:"''",typeName:"str",isKwarg:!1,dashesInitialValue:'"Send your code here!"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"language",description:"The programming language. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"language",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Show me the code!",language:"c",initialValue:`#include<stdio.h>
int main(int argc, char** argv) {
char name[256];
scanf("%s", name);
printf("%s, here is", name);
}`},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_code",key:"example1",code:`from abstra.forms import read_code

ans = read_code("Show me the code!", language="c")
`}]},"cpf-input":{name:"CPF input",description:"Allow users to insert a CPF number into the app.",type:"cpf-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:222,minHeight:70,initialWidth:222,initialHeight:112},pythonAPI:{name:"read_cpf",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Insert your CPF here!"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",typeDescription:["str (000.000.000-00)"],isKwarg:!0,default:'""',formOnly:!0},{argName:"invalid_message",description:"The message to display when the user enters an invalid value. Defaults to None.",typeName:"str",isKwarg:!0,default:"None",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "000.000.000-00".',typeName:"str",typeDescription:["str (000.000.000-00)"],isKwarg:!0,default:'"000.000.000-00"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"invalidMessage",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"Insert your CPF below"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_cpf",key:"example1",code:`from abstra.forms import read_cpf

name = read_cpf("Insert your CPF below")
`}]},"currency-input":{name:"Currency input",description:"Currency input allows users to enter monetary values.",type:"currency-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:100,minHeight:72,initialWidth:300,initialHeight:112},pythonAPI:{name:"read_currency",params:[{argName:"label",description:"The label to display to the user",default:"''",typeName:"str",isKwarg:!1,dashesInitialValue:'"Insert the proper amount."'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to 0.",typeName:"str",isKwarg:!0,default:"0",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"min",description:'The minimum value allowed, eg. "0". Defaults to None.',typeName:"float",isKwarg:!0,default:"None"},{argName:"max",description:'The maximum value allowed, eg. "100". Defaults to None.',typeName:"float",isKwarg:!0,default:"None"},{argName:"currency",description:'The currency to display to the user, eg. "USD", "BRL, "EUR", "GBP". Defaults to "USD".',typeName:"str",isKwarg:!0,default:'"USD"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"float",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"currency",typeName:"string"},{argName:"value",typeName:["number","null"],default:null},{argName:"min",typeName:["number","null"]},{argName:"max",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"How many credits do you want?",initialValue:10,min:10,currency:"USD"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_currency",key:"example1",code:`from abstra.forms import read_currency

read_currency(
    f"How many credits do you want?", currency="USD", initial_value=10, min=10
)
`}]},"custom-input":{type:"custom-input",name:"Custom widget",description:"Widget with customizable UI and behaviour",autoHeight:!1,events:[{key:"custom-event",description:"Function or expression to be run when custom event is triggered",payloadSchema:[]},{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:65,minHeight:30,initialWidth:146,initialHeight:32},pythonAPI:{name:"read_custom",params:[{argName:"html_body",description:"The HTML body content",typeName:"str",typeDescription:["str (HTML snippet)"],isKwarg:!1,default:"''",dashesInitialValue:'"<h1>Hello World</h1>"'},{argName:"initial_value",description:"The initial value to be stored in custom widget state.",typeName:"Any",isKwarg:!0,default:"None",formOnly:!0},{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!0,default:"''"},{argName:"html_head",description:"The HTML head content",typeName:"str",typeDescription:["str (HTML snippet)"],isKwarg:!0,default:"''",dashesInitialValue:'""'},{argName:"css",description:"The widget's CSS",typeName:"str",typeDescription:["str (CSS snippet)"],isKwarg:!0,default:"''",dashesInitialValue:'"h1 { color: red; }"'},{argName:"js",description:"The widget's JavaScript",typeName:"str",typeDescription:["str (JavaScript snippet)"],isKwarg:!0,default:"''",dashesInitialValue:`"console.log('Hello World')"`},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Any",typeDescription:"The custom response"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:["string","number","boolean","object","null"],default:null},{argName:"htmlHead",typeName:"string"},{argName:"htmlBody",typeName:"string"},{argName:"css",typeName:"string"},{argName:"js",typeName:"string"},{argName:"key",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{htmlBody:"<button id='date-btn'>Get current date</button>",js:`document.getElementById('date-btn').addEventListener('click',function() {
    const date = new Date();
    const day = date.getDate();
    const month = date.getMonth() + 1;
    const year = date.getFullYear();

    changeEvent(day + '/' + month + '/' + year);
});`,css:`body {
    margin: 0;
    padding: 0;
}

#date-btn {
    cursor: pointer;
    background-color: #343b46;
    border: none;
    border-radius: 4px;
    color: white;
    padding: 15px 32px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
}

#date-btn:hover {
    background-color: #3e4756;
}`,label:"Custom Widget"},name:"Basic Example",description:"The following example shows how to create a custom widget with a button that returns the current date.",key:"example1",code:`from abstra.forms import read_custom

current_date = read_custom(
    "<button id='date-btn'>Get current date</button>",
    label="Custom Widget",
    js="""
    document.getElementById('date-btn').addEventListener('click',function() {
        const date = new Date();
        const day = date.getDate();
        const month = date.getMonth() + 1;
        const year = date.getFullYear();

        changeEvent(day + '/' + month + '/' + year);
    });
    """,
    css="""
    body {
        margin: 0;
        padding: 0;
    }

    #date-btn {
        cursor: pointer;
        background-color: #343b46;
        border: none;
        border-radius: 4px;
        color: white;
        padding: 15px 32px;
        text-align: center;
        text-decoration: none;
        display: inline-block;
        font-size: 16px;
    }

    #date-btn:hover {
        background-color: #3e4756;
    }
    """,
)
`}]},"date-input":{name:"Date picker input",description:"Allow users to select  a date, or a range of dates.*",type:"date-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:200,minHeight:72,initialWidth:300,initialHeight:112},pythonAPI:{name:"read_date",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Pick a date of your preference."'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to None.",typeName:"Union[datetime.date, time.struct_time, str]",typeDescription:["datetime.date","time.struct_time","str (YYYY-MM-DD)"],isKwarg:!0,default:"None",formOnly:!0},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"datetime.date",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"When were you born?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_date",key:"example1",code:`from abstra.forms import read_date

birthday = read_date("When were you born?")
year = birthday.year
month = birthday.month
day = birthday.day
`}]},"dropdown-input":{name:"Dropdown",description:"Allow users to select one or more options by selecting items in a dropdown",type:"dropdown-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:60,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_dropdown",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'""'},{argName:"options",description:"The options to display to the user, eg. ['Option 1', 'Option 2'] or [{'label': 'Option 1', 'value': '1'}, {'label': 'Option 2', 'value': '2'}]",typeName:"list",typeDescription:["list[AbstraOption]"],isKwarg:!1,default:"None",dashesInitialValue:`[
    {
      "label": "Option 1",
      "value": 1,
    },
    {
      "label": "Option 2",
      "value": 2,
    },
  ]`},{argName:"multiple",description:"Whether the user can select multiple options. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"initial_value",description:"The initial value to display to the user. Defaults to [].",typeName:"str or list",isKwarg:!0,default:"[]",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "Choose an option".',typeName:"str",isKwarg:!0,default:'"Choose an option"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value selected by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"array",default:[]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"options",typeName:"array",items:{typeName:["string","object"],properties:[{argName:"key",typeName:"string",description:"The key of the option on the returning object"},{argName:"value",typeName:"object",description:"The value of the option on the returning object"}]}},{argName:"placeholder",typeName:"string"},{argName:"multiple",typeName:"boolean"}]},examples:[{props:{label:"Choose a color",options:["Red","Green","Blue"]},name:"Basic Example",description:"Basic use of read_dropdown",key:"example1",code:`from abstra.forms import read_dropdown

ans = read_dropdown(
    "Choose a color",
    ["Red", "Green", "Blue"],
)
# ans = "Red", "Green" or "Blue"
`},{props:{label:"Choose a color",options:["Red","Green","Blue"]},name:"Label and value dict",description:"Use a dictionary to specify the label and value of each option. The label will be displayed to the user, and the value will be returned by the widget.",key:"example2",code:`from abstra.forms import read_dropdown

ans = read_dropdown(
    "Choose a color",
    [
        {"label": "Red", "value": "R"},
        {"label": "Green", "value": "G"},
        {"label": "Blue", "value": "B"},
    ],
)
# ans = "R", "G" or "B"
`}]},"email-input":{name:"Email input",description:"Email input allow users to enter a valid email address.",type:"email-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:220,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_email",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Insert your email"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"invalid_email_message",typeName:"str",description:"Invalid e-mail message",isKwarg:!0,default:`"Hmm\u2026 doesn't look like an email"`},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"invalidEmailMessage",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"What is your email?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_email",key:"example1",code:`from abstra.forms import read_email

email = read_email("What is your email?")
`}]},"file-input":{name:"File upload area",description:"File upload adds a drop-area for users to upload one or more files",type:"file-input",autoHeight:!1,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:150,minHeight:112,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_file",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Upload a file."'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:"None",formOnly:!0},{argName:"multiple",description:"Whether the user will be allowed to upload multiple files. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"max_file_size",description:"Maximum size allowed to be transfered in total in MB.",typeName:"float",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Union[FileResponse, List[FileResponse]]",typeDescription:"A dict containing the file uploaded by the user FileResponse(file: TemporaryFile, url: str, content: bytes) or a list of FileResponses in case of multiple flag set as True. \u26A0\uFE0F The url expires after 48 hours"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:["array"],default:[]},{argName:"multiple",typeName:"boolean"},{argName:"maxFileSize",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Upload your .xlsx file"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_file",key:"example1",code:`from abstra.forms import read_file

file_response = read_file("Upload your .xlsx file")
file = file_response.file  # File object
`},{props:{label:"Upload your file"},name:"Saving file to a directory on Files storage",description:"This example shows how to save a file to a directory on Files",key:"example2",code:`from abstra.forms import read_file
import shutil, os

file_response = read_file("Upload your file")

destination_dir = "foo/bar/"
# Creates directory if it does not exist
os.makedirs(destination_dir, exist_ok=True)

# Copies file to destination directory
shutil.copy(file_response.file.name, destination_dir + file_response.name)
`}]},"image-input":{name:"Image upload",description:"Image upload adds a drop-area for users to upload one or more image files.",type:"image-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!1,dashProperties:{minWidth:150,minHeight:112,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_image",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:"''",dashesInitialValue:'"Upload"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"multiple",description:"Whether the user will be allowed to upload multiple files. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"max_file_size",description:"Maximum size allowed to be transfered in total in MB.",typeName:"float",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Union[FileResponse, List[FileResponse]]",typeDescription:'A dict containing the image file uploaded by the user ({"file": file, "url": str, "content": bytes}) or a list of images in case of multiple flag set as True'}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"array",default:[]},{argName:"maxFileSize",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"multiple",typeName:"boolean"}]},examples:[{props:{label:"Upload your .png image"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_image",key:"example1",code:`from abstra.forms import read_image

file_response = read_image("Upload your .png image")
file = file_response.file  # File object
`}]},"kanban-board-input":{name:"Kanban board",description:"Kanban board",type:"kanban-board-input",dashOnly:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!1,dashProperties:{minWidth:300,minHeight:500,initialWidth:500,initialHeight:500},pythonAPI:{name:"read_kanban_board",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null},{argName:"initial_value",description:"The initial board state.",typeName:"List[KanbanCard]",isKwarg:!0,default:null,formOnly:!0},{argName:"stages",description:"List of stages",typeName:"List[KanbanStage]",isKwarg:!0,default:null,dashesInitialValue:'["To do", "In progress", "Done"]'}],returns:[{typeName:"KanbanBoard",typeDescription:"Object containing all stages and cards"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"array",default:[]},{argName:"stages",typeName:"array"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"}]},examples:[{props:{initialValue:{type:"kanban-board",stages:[{type:"kanban-stage",name:"Backlog",cards:[{type:"kanban-card",name:"Add a new feature #1",description:"Add a new feature to the product",tags:["feature","enhancement"]},{type:"kanban-card",name:"Fix a bug #2",description:"Fix a bug in the product",tags:["bug"]}]},{type:"kanban-stage",name:"In progress",cards:[{type:"kanban-card",name:"Add a new feature #3",description:"Add a new feature to the product",tags:["feature","enhancement"]},{type:"kanban-card",name:"Fix a bug #4",description:"Fix a bug in the product",tags:["bug"]}]},{type:"kanban-stage",name:"Done",cards:[{type:"kanban-card",name:"Add a new feature #5",description:"Add a new feature to the product",tags:["feature","enhancement"]},{type:"kanban-card",name:"Fix a bug #6",description:"Fix a bug in the product",tags:["bug"]}]}]},label:"Spring backlog"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_kanban_board",key:"example1",code:`from abstra.forms import read_kanban_board

board = {
    "type": "kanban-board",
    "stages": [
        {
            "type": "kanban-stage",
            "name": "Backlog",
            "cards": [
                {
                    "type": "kanban-card",
                    "name": "Add a new feature #1",
                    "description": "Add a new feature to the product",
                    "tags": ["feature", "enhancement"],
                },
                {
                    "type": "kanban-card",
                    "name": "Fix a bug #2",
                    "description": "Fix a bug in the product",
                    "tags": ["bug"],
                },
            ],
        },
        {
            "type": "kanban-stage",
            "name": "In progress",
            "cards": [
                {
                    "type": "kanban-card",
                    "name": "Add a new feature #3",
                    "description": "Add a new feature to the product",
                    "tags": ["feature", "enhancement"],
                },
                {
                    "type": "kanban-card",
                    "name": "Fix a bug #4",
                    "description": "Fix a bug in the product",
                    "tags": ["bug"],
                },
            ],
        },
        {
            "type": "kanban-stage",
            "name": "Done",
            "cards": [
                {
                    "type": "kanban-card",
                    "name": "Add a new feature #5",
                    "description": "Add a new feature to the product",
                    "tags": ["feature", "enhancement"],
                },
                {
                    "type": "kanban-card",
                    "name": "Fix a bug #6",
                    "description": "Fix a bug in the product",
                    "tags": ["bug"],
                },
            ],
        },
    ],
}

read_kanban_board(label="Product spring", initial_value=board)
`}]},"list-input":{name:"List of inputs",description:"Read a list value from the user",type:"list-input",formOnly:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:146,minHeight:32,initialWidth:146,initialHeight:32},pythonAPI:{name:"read_list",params:[{argName:"item_schema",description:"The schema for the items of the list",typeName:"Any",isKwarg:!1,default:null},{argName:"initial_value",description:"''",typeName:"array",isKwarg:!0,default:"[]",formOnly:!0},{argName:"min",description:"Min value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"max",description:"Max value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"add_button_text",description:"''",typeName:"str",isKwarg:!0,default:'"+"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"list",typeDescription:"The values entered by the user"}]},brokerAPI:{params:[{argName:"value",typeName:"array",default:[]},{argName:"min",typeName:"number"},{argName:"max",typeName:"number"},{argName:"addButtonText",typeName:"string"},{argName:"schemas",typeName:"array"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{initialValue:[{}],min:1,max:3,itemSchema:[{hint:null,initialValue:"",key:"Name",label:"Name",placeholder:"",required:!0,type:"text-input"},{hint:null,initialValue:"",key:"Email",label:"Email",placeholder:"",required:!0,type:"email-input"}]},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_list",key:"example1",code:`from abstra.forms import ListItemSchema, read_list

item = ListItemSchema().read("Name").read_email("Email")
ans = read_list(item, min=1, max=3)
# ans = [{'Name': '', 'Email': ''}]
`}]},"multiple-choice-input":{name:"Multiple choice",description:"Read a multiple choice value from the user",type:"multiple-choice-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:60,minHeight:70,initialWidth:223,initialHeight:152},pythonAPI:{name:"read_multiple_choice",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Select your choices"'},{argName:"options",description:"The options to display to the user, eg. ['Option 1', 'Option 2'] or [{'label': 'Option 1', 'value': '1'}, {'label': 'Option 2', 'value': '2'}]",typeName:"list",typeDescription:["list[AbstraOption]"],isKwarg:!1,default:"None",dashesInitialValue:`[
    {
      "label": "Option 1",
      "value": 1,
    },
    {
      "label": "Option 2",
      "value": 2,
    },
  ]`},{argName:"multiple",description:"Whether the user can select multiple options. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"min",description:"The minimal amount of options that should be selected. Defaults to None.",typeName:"number",isKwarg:!0,default:"None"},{argName:"max",description:"The maximum amount of options that should be selected. Defaults to None.",typeName:"number",isKwarg:!0,default:"None"},{argName:"initial_value",description:"The initial value of the selection. Defaults to [].",typeName:"[]",isKwarg:!0,default:"None",formOnly:!0},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Union[list, any]",typeDescription:"The values/value selected by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"multiple",typeName:"boolean"},{argName:"value",typeName:"array",default:[]},{argName:"min",typeName:["number","null"]},{argName:"max",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"options",typeName:"array",items:{typeName:["string","object"],properties:[{argName:"key",typeName:"string",description:"The key of the option on the returning object"},{argName:"value",typeName:"object",description:"The value of the option on the returning object"}]}}]},examples:[{props:{label:"Which programming language do you prefer?",options:["Python","JavaScript"]},name:"Basic Example",description:"Basic use of read_multiple_choice",key:"example1",code:`from abstra.forms import read_multiple_choice

ans = read_multiple_choice(
    "Which programming language do you prefer?",
    ["Python", "JavaScript"],
)
# ans = "Python" or "JavaScript"
`},{props:{label:"Which programming language do you prefer?",options:["Python","JavaScript"]},name:"Label and value dict",description:"Use a dictionary to specify the label and value of each option. The label will be displayed to the user, and the value will be returned by the widget.",key:"example2",code:`from abstra.forms import read_multiple_choice

ans = read_multiple_choice(
    "Which programming language do you prefer?",
    [{"label": " Python", "value": "py"}, {"label": "JavaScript", "value": "js"}],
)
# ans = "py" or "js"
`},{props:{label:"What features do you love?",options:["forms","jobs","hooks"],multiple:!0},name:"Checkboxes",description:"Use `multiple=true` when you want allow users to select more than one option. This will make it returns a list.",key:"example3",code:`from abstra.forms import read_multiple_choice

ans = read_multiple_choice(
    "What features do you love?", ["forms", "jobs", "hooks"], multiple=True
)
# ans = ["forms", "jobs", "hooks"]
`}]},"nps-input":{name:"NPS feedback",description:"NPS feedback allow users to rank their experience from 0 to 10.",type:"nps-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:120,minHeight:60,initialWidth:608,initialHeight:112},pythonAPI:{name:"read_nps",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Rate us!"'},{argName:"min",description:"Min value accepted by the input. Defaults to 0.",typeName:"int",isKwarg:!0,default:"0"},{argName:"max",description:"Max value accepted by the input. Defaults to 10.",typeName:"int",isKwarg:!0,default:"10"},{argName:"min_hint",description:'Text to display next to the min value. Defaults to "Not at all likely".',typeName:"str",isKwarg:!0,default:'"Not at all likely"'},{argName:"max_hint",description:'Text to display next to the max value. Defaults to "Extremely likely".',typeName:"str",isKwarg:!0,default:'"Extremely likely"'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to None.",typeName:"str",typeDescription:["str (nps format)"],isKwarg:!0,default:"None",formOnly:!0},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"int",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"min",typeName:["number","null"]},{argName:"max",typeName:["number","null"]},{argName:"minHint",typeName:"string"},{argName:"maxHint",typeName:"string"},{argName:"value",typeName:["number","null"],default:null},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"How likely are you to recommend Abstra Cloud?",minHint:"No way!",maxHint:"Hell yeah!"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_nps",key:"example1",code:`from abstra.forms import read_nps

ans = read_nps(
    "How likely are you to recommend Abstra Cloud?",
    min_hint="No way!",
    max_hint="Hell yeah!",
)
`}]},"number-input":{name:"Number input",description:"Number input allow users to enter numeric values.",type:"number-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_number",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Number"'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to 0.",typeName:"str",isKwarg:!0,default:"0",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"min",description:"Min value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"max",description:"Max value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"float",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:["number","null"],default:null},{argName:"min",typeName:["number","null"]},{argName:"max",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"How old are you?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_number",key:"example1",code:`from abstra.forms import read_number

age = read_number("How old are you?")
`}]},"number-slider-input":{name:"Number slider",description:"Allow users to select values in a slider bar. ",type:"number-slider-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:120,minHeight:30,initialWidth:223,initialHeight:72},pythonAPI:{name:"read_number_slider",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Select a value!"'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to 0.",typeName:"float",isKwarg:!0,default:"0",formOnly:!0},{argName:"min",description:"Min value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"max",description:"Max value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"step",description:"The value to be incremented or decremented while using the input button. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"float",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"number",default:0},{argName:"min",typeName:"number"},{argName:"max",typeName:"number"},{argName:"step",typeName:"number"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Set volume"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_number",key:"example1",code:`from hackeforms import read_number_slider

age = read_number_slider("Set volume")
`}]},"pandas-row-selection-input":{name:"Table with selection",description:"Display a pandas dataframe as a table and allow the user to select rows",type:"pandas-row-selection-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!1,dashProperties:{minWidth:200,minHeight:250,initialWidth:500,initialHeight:500},pythonAPI:{name:"read_pandas_row_selection",params:[{argName:"df",description:"The pandas dataframe to be displayed",typeName:"PandasDataFrame",isKwarg:!1,default:null},{argName:"display_index",description:"Whether to show a index column. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!0,default:null},{argName:"multiple",description:"Whether the user will be allowed to select multiple rows. Defaults to True.",typeName:"bool",isKwarg:!0,default:"True"},{argName:"initial_value",description:"The initial value of the selection. Defaults to []",typeName:"list",isKwarg:!0,default:"[]"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"list",typeDescription:"The list of selected rows"}]},brokerAPI:{params:[{argName:"table",typeName:"object",properties:[{argName:"data",typeName:"array"},{argName:"schema",typeName:"object",properties:[{argName:"fields",typeName:"array"}]}]},{argName:"displayIndex",typeName:"boolean"},{argName:"label",typeName:"string"},{argName:"value",typeName:"array",default:[]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"multiple",typeName:"boolean"}]},examples:[{props:{table:{schema:{fields:[{name:"Country",type:"string"},{name:"Population",type:"number"}],primaryKey:["Country"]},data:[{Country:"USA",Population:"32,700,000"},{Country:"China",Population:"1,300,000,000"},{Country:"Japan",Population:"126,000,000"}]}},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_pandas",key:"example1",code:`from abstra.forms import read_pandas_row_selection
import pandas as pd

data = [
    {"Country": "USA", "Population": "32,700,000"},
    {"Country": "China", "Population": "1,300,000,000"},
    {"Country": "Japan", "Population": "126,000,000"},
]
df = pd.DataFrame(data)
read_pandas_row_selection(df)
`}]},"password-input":{name:"Password input",type:"password-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,description:"Password input allow users to enter a password before seen the content.",dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_password",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert Your password"'},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"lowercase_required",description:"Whether the input must have at least one lowercase character. Defaults to True.",typeName:"bool",isKwarg:!0,default:"True"},{argName:"uppercase_required",description:"Whether the input must have at least one uppercase character. Defaults to True.",typeName:"bool",isKwarg:!0,default:"True"},{argName:"special_required",description:"Whether the input must have at least one special character. Defaults to True.",typeName:"bool",isKwarg:!0,default:"True"},{argName:"digit_required",description:"Whether the input must have at least one digit. Defaults to True.",typeName:"bool",isKwarg:!0,default:"True"},{argName:"min_length",description:"Minimum length of the password. Defaults to 8.",typeName:"int",isKwarg:!0,default:"8"},{argName:"max_length",description:"Maximum length of the password. Defaults to None.",typeName:"int",isKwarg:!0,default:"None"},{argName:"size",description:"Size of the password. Defaults to None.",typeName:"int",isKwarg:!0,default:"None"},{argName:"pattern",description:"A regex pattern for the accepted password. Defaults to None.",typeName:"str",typeDescription:["str (regex)"],isKwarg:!0,default:"None"},{argName:"autocomplete",description:'The autocomplete HTML attribute. Defaults to "current-password".',typeName:"str",typeDescription:["str ('off', 'name', 'email', 'username', 'current-password', 'new-password')"],isKwarg:!0,default:'"current-password"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"lowercaseRequired",typeName:["boolean","string"]},{argName:"uppercaseRequired",typeName:["boolean","string"]},{argName:"specialRequired",typeName:["boolean","string"]},{argName:"digitRequired",typeName:["boolean","string"]},{argName:"minLength",typeName:"number"},{argName:"maxLength",typeName:["number","null"]},{argName:"size",typeName:["number","null"]},{argName:"pattern",typeName:["string","null"]},{argName:"autocomplete",typeName:"string"},{argName:"secret",typeName:"boolean"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"Insert your password below"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_password",key:"example1",code:`from abstra.forms import read_password

ans = read_password("Insert your password below")
`}]},"phone-input":{name:"Phone input",description:"Phone input allow users to enter a valid phone number.",type:"phone-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:377,minHeight:60,initialWidth:377,initialHeight:112},pythonAPI:{name:"read_phone",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert a phone number."'},{argName:"initial_value",description:"The initial value to display to the user. It contains two keys: 'country_code' (string with optional + sign or number) and 'national_number' (str). Ex: {'country_code': '55', 'national_number': '21999990000'}.",typeName:"dict",typeDescription:['dict ({"country_code": str, "national_number": str})'],isKwarg:!0,default:'{"country_code": "", "national_number": ""}',formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"invalid_message",typeName:"str",isKwarg:!0,default:'"Invalid phone number."',description:"The message to display when the input is invalid"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"PhoneResponse",typeDescription:'A dict containing the value entered by the user ({"country_code": str, "national_number": str})'}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"object",default:{countryCode:"",nationalNumber:""},properties:[{argName:"countryCode",typeName:"string"},{argName:"nationalNumber",typeName:"string"}]},{argName:"invalidMessage",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"What is your phone number?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_phone",key:"example1",code:`from abstra.forms import read_pandas_row_selection

phone = read_phone("What is your phone number?")
number = phone.raw  # eg: 5521999999999
masked = phone.masked  # eg: +55 (21) 99999-9999
`}]},"rating-input":{name:"Rating feedback",description:"Rating feedback allow users to rank their experience from 1 to 5 starts.",type:"rating-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:72},pythonAPI:{name:"read_rating",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Rate us!"'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to 0.",typeName:"int",isKwarg:!0,default:"0",formOnly:!0},{argName:"max",description:"Max value accepted by the input. Defaults to None.",typeName:"float",isKwarg:!0,default:"None"},{argName:"char",description:"Which char should be displayed as icon?",typeName:"str",typeDescription:["str (unicode-character)"],isKwarg:!0,default:"\u2B50\uFE0F"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"float",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:["number","null"],default:null},{argName:"max",typeName:"number"},{argName:"char",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"How much do you rate this movie?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_rating",key:"example1",code:`from abstra.forms import read_rating

rating = read_rating("How do you rate this movie?")
`},{props:{label:"How do you evaluate your Python skills?",char:"\u{1F40D}",max:3},name:"Custom chars and number of points",description:"The following example demonstrate some of the available functionality for read_rating",key:"example2",code:`from abstra.forms import read_rating

rating = read_rating("How do you evaluate your Python skills?", char="\u{1F40D}", max=3)
`}]},"rich-text-input":{name:"Rich text input",type:"rich-text-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],description:"Rich text input allows users to type and format textual content.",autoHeight:!1,dashProperties:{minWidth:100,minHeight:100,initialWidth:200,initialHeight:150},pythonAPI:{name:"read_richtext",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert your rich text here!"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "Your rich text here".',typeName:"str",isKwarg:!0,default:'"Your rich text here"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The rich text value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"Write here your bio"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_richtext",key:"example1",code:`read_richtext("Write here your bio")
`}]},"tag-input":{name:"Tag input",type:"tag-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],description:"Read a tag value from the user",dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_tag",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert the desired tags."'},{argName:"initial_value",description:"The initial value to display to the user. Defaults to [].",typeName:"list",typeDescription:["list[str]"],isKwarg:!0,default:"[]",formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"List[str]",typeDescription:"The values entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:["array"],default:[]},{argName:"placeholder",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Type and press enter to add a tag",initialValue:["Red","Green","Blue"]},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_tag",key:"example1",code:`from abstra.forms import read_tag

ans = read_tag(
    "Type and press enter to add a tag", initial_value=["Red", "Green", "Blue"]
)
# ans = ["Red", "Green" or "Blue"]\`
`}]},"text-input":{name:"Text input",description:"Text fields allow users to insert plain text.",type:"text-input",autoHeight:!0,events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert your text here!"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "Placeholder".',typeName:"str",isKwarg:!0,default:'"Placeholder"'},{argName:"mask",description:"A mask to apply to the input. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"mask",typeName:["string","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"What is your name?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read",key:"example1",code:`from abstra.forms import read

name = read("What is your name?")
`},{props:{label:"What is your credit card number?",mask:"0000 0000 0000 0000"},name:"Mask Example",description:"The following example shows the usage of the mask property for read widget. In the mask property, the '0' digit represents a numeric value, the 'a' digit represents an alphabetic value and other digits are recognized as part of the value",key:"example2",code:`from abstra.forms import read

read("What is your credit card number?", mask="0000 0000 0000 0000")
`}]},"textarea-input":{name:"Long text input",type:"textarea-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],description:"Long text input allow users to type longer textual content.",autoHeight:!1,dashProperties:{minWidth:100,minHeight:100,initialWidth:200,initialHeight:150},pythonAPI:{name:"read_textarea",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Insert your text here!"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""',formOnly:!0},{argName:"placeholder",description:'The placeholder text to display to the user. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"str",typeDescription:"The value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"string",default:""},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"placeholder",typeName:"string"}]},examples:[{props:{label:"What kind of things are you building with Abstra Cloud?"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_textarea",key:"example1",code:`from abstra.forms import read_textarea

ans = read_textarea("What kind of things are you building with Abstra Cloud?")
`}]},"time-input":{name:"Time input",type:"time-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,description:"Read a time value from the user",dashProperties:{minWidth:120,minHeight:60,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_time",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Choose the desired time."'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "00:00".',typeName:"str or datetime.time",typeDescription:["str (HH:MM:SS)","datetime.time"],isKwarg:!0,default:'""',formOnly:!0},{argName:"format",description:'Whether the input is in the format 24hs or AM/PM. Defaults to "24hs".',typeName:"str",isKwarg:!0,default:'"24hs"'},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"datetime.time",typeDescription:"A datetime.time object representing the value entered by the user"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"object",properties:[{argName:"hour",typeName:"number"},{argName:"minute",typeName:"number"}],default:{hour:0,minute:0}},{argName:"format",typeName:"string"},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Select a time below"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_time",key:"example1",code:`from abstra.forms import read

ans = read_time("Select a time below")
# ans = 00:00:00
`}]},"toggle-input":{name:"Toggle",description:"Allow users to set between two items.",type:"toggle-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!0,dashProperties:{minWidth:120,minHeight:60,initialWidth:377,initialHeight:112},pythonAPI:{name:"read_toggle",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Click to confirm the following options"'},{argName:"on_text",description:"Text of On Toggle option",typeName:"str",isKwarg:!0,default:"Yes"},{argName:"off_text",description:"Text of Off Toggle option",typeName:"str",isKwarg:!0,default:"No"},{argName:"initial_value",description:"Initial value of the toggle",typeName:"bool",isKwarg:!0,default:"No"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"bool",typeDescription:"The toggle value"}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"onText",typeName:"string"},{argName:"offText",typeName:"string"},{argName:"value",typeName:"boolean",default:!1},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{label:"Toggle",onText:"On",offText:"Off"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_toggle",key:"example1",code:`from abstra.forms import read_toggle

ans = read_toggle("Toggle")
# ans = True or False
print(ans)
`},{props:{label:"Custom Toggle",onText:"Confirm",offText:"Cancel"},name:"Custom Example",description:"The following example demonstrate how to customize the toggle options text",key:"example2",code:`from abstra.forms import read_toggle

ans = read_toggle("Custom Toggle", on_text="Confirm", off_text="Cancel")
# ans = True or False
`}]},"video-input":{name:"Video upload",description:"Video upload adds a drop-area for users to upload one or more video files.",type:"video-input",events:[{key:"update:value",description:"Function or expression to be run when the input value changes",payloadSchema:[]}],autoHeight:!1,dashProperties:{minWidth:150,minHeight:112,initialWidth:223,initialHeight:112},pythonAPI:{name:"read_video",params:[{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Upload your video"'},{argName:"initial_value",description:'The initial value to display to the user. Defaults to "".',typeName:"Union[str, io.IOBase]",typeDescription:["io.IOBase","str (filepath)","str (URL)"],isKwarg:!0,default:'""',formOnly:!0},{argName:"multiple",description:"Whether the user will be allowed to upload multiple files. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"max_file_size",description:"Maximum size allowed to be transfered in total in MB.",typeName:"float",isKwarg:!0,default:"None"},{argName:"disabled",description:"whether the input is disabled. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"required",description:'Whether the input is required or not eg. "this field is required". Defaults to True.',typeName:"Union[bool, str]",typeDescription:["bool","str"],isKwarg:!0,default:"True",formOnly:!0},{argName:"hint",description:"A tooltip displayed to the user. Defaults to None.",typeName:"str",isKwarg:!0,default:"None"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[{typeName:"Union[FileResponse, List[FileResponse]]",typeDescription:'A dict containing the video uploaded by the user ({"file": file, "url": str, "content": bytes}) or a list of videos in case of multiple flag set as True'}]},brokerAPI:{params:[{argName:"label",typeName:"string"},{argName:"value",typeName:"array",items:{typeName:"string"},default:[]},{argName:"maxFileSize",typeName:["number","null"]},{argName:"key",typeName:"string"},{argName:"disabled",typeName:"boolean"},{argName:"errors",typeName:"array"},{argName:"hint",typeName:["string","null"]},{argName:"required",typeName:["string","boolean"]},{argName:"fullWidth",typeName:"boolean"},{argName:"multiple",typeName:"boolean"}]},examples:[{props:{label:"Upload your video"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_video",key:"example1",code:`from abstra.forms import read_video

file_response = read_video("Upload your video")
file = file_response.file  # File object
`}]},"file-output":{name:"Download file",description:"Show a button for the user to download a file.",type:"file-output",autoHeight:!0,events:[],dashProperties:{minWidth:65,minHeight:30,initialWidth:223,initialHeight:72},pythonAPI:{name:"display_file",params:[{argName:"file",description:"The file to download",typeName:"Union[str, io.IOBase]",typeDescription:["io.IOBase","str (filepath)","str (URL)"],isKwarg:!1,default:"None",dashesInitialValue:'"https://gist.github.com/armgilles/194bcff35001e7eb53a2a8b441e8b2c6/archive/92200bc0a673d5ce2110aaad4544ed6c4010f687.zip"'},{argName:"download_text",description:'The text to display on the button that will download the file. Defaults to "Download here".',typeName:"str",isKwarg:!0,default:'"Download"'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"fileUrl",typeName:"string"},{argName:"downloadText",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{fileUrl:"https://placekitten.com/200/300",downloadText:"Click here to reveal the secret"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_file",key:"example1",code:`from abstra.forms import display_file

display_file(
    "https://placekitten.com/200/300", download_text="Click here to reveal the secret"
)
`}]},"html-output":{name:"HTML",description:"Embed HTML to the app.",type:"html-output",events:[],autoHeight:!0,dashProperties:{minWidth:65,minHeight:30,initialWidth:146,initialHeight:32},pythonAPI:{name:"display_html",params:[{argName:"html",description:"The html snippet to display to the user",typeName:"str",typeDescription:["str (html snippet)"],isKwarg:!1,default:"''",dashesInitialValue:'"<div>Hello World</div>"'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"html",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{html:'<svg width="100" height="100"><circle cx="50" cy="50" r="40" stroke="green" stroke-width="4" fill="yellow" /></svg>'},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_html",key:"example1",code:`from abstra.forms import display_html

display_html(
    '<svg width="100" height="100"><circle cx="50" cy="50" r="40" stroke="green" stroke-width="4" fill="yellow" /></svg>'
)
`}]},"iframe-output":{name:"iframe",description:"Embed content using iframe.",type:"iframe-output",events:[],autoHeight:!1,dashProperties:{minWidth:377,minHeight:100,initialWidth:377,initialHeight:632},pythonAPI:{name:"display_iframe",params:[{argName:"url_or_html",description:"The link to the document or the own document to display to the user",typeName:"str",typeDescription:["str (URL)","str (html snippet)"],isKwarg:!1,default:"''",dashesInitialValue:'"<div>Hello World</div>"'},{argName:"width",description:'The width of the iframe. Defaults to "800".',typeName:"int",typeDescription:["int (pixels)"],isKwarg:!0,default:'"800"'},{argName:"height",description:'The height of the iframe. Defaults to "600".',typeName:"int",typeDescription:["int (pixels)"],isKwarg:!0,default:'"600"'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"url",typeName:"string"},{argName:"width",typeName:["string","null"]},{argName:"height",typeName:["string","null"]},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{url:"https://www.google.com/maps/embed?pb=!1m16!1m12!1m3!1d2965.0824050173574!2d-93.63905729999999!3d41.998507000000004!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!2m1!1sWebFilings%2C+University+Boulevard%2C+Ames%2C+IA!5e0!3m2!1sen!2sus!4v1390839289319",width:"300",height:"250"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_iframe",key:"example1",code:`from abstra.forms import display_iframe

display_iframe(
    "https://www.google.com/maps/embed?pb=!1m16!1m12!1m3!1d2965.0824050173574!2d-93.63905729999999!3d41.998507000000004!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!2m1!1sWebFilings%2C+University+Boulevard%2C+Ames%2C+IA!5e0!3m2!1sen!2sus!4v1390839289319",
    width="300",
    height="250",
)
`}]},"image-output":{name:"Show image",description:"Show an image to the user",type:"image-output",events:[],autoHeight:!1,dashProperties:{minWidth:60,minHeight:60,initialWidth:223,initialHeight:312},pythonAPI:{name:"display_image",params:[{argName:"image",description:"The image to display to the user",typeName:"Union[str, io.IOBase]",typeDescription:["io.IOBase","str (filepath)","str (URL)"],isKwarg:!1,default:"None",dashesInitialValue:'"https://upload.wikimedia.org/wikipedia/commons/thumb/6/6a/Mona_Lisa.jpg/396px-Mona_Lisa.jpg"'},{argName:"subtitle",description:'The subtitle of the image. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!0,default:"''"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"imageUrl",typeName:"string"},{argName:"subtitle",typeName:"string"},{argName:"label",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{imageUrl:"https://placekitten.com/200/200",subtitle:"Meooow"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_image",key:"example1",code:`from abstra.forms import display_image

display_image("https://placekitten.com/200/200", subtitle="Meooow")
`}]},"latex-output":{name:"Show Latex formula",description:"Show an Latex formula to the user",type:"latex-output",events:[],autoHeight:!0,dashProperties:{minWidth:60,minHeight:30,initialWidth:146,initialHeight:32},pythonAPI:{name:"display_latex",params:[{argName:"text",description:"The latex formula to display to the user",typeName:"str",typeDescription:["str (latex snippet)"],isKwarg:!1,default:null,dashesInitialValue:'"\\(x^2 + y^2 = z^2\\)"'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"text",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{text:"\\(ax^2 + bx + c = 0\\)"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_latex",key:"example1",code:`from abstra.forms import display_latex

display_latex("\\(ax^2 + bx + c = 0\\)")
`},{props:{text:"When \\(a \\ne 0\\), there are two solutions to \\(ax^2 + bx + c = 0\\) and they are $$x = {-b \\pm \\sqrt{b^2-4ac} \\over 2a}.$$"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_latex",key:"example2",code:`from abstra.forms import display_latex

display_latex(
    """When \\(a \\\\ne 0\\), there are two solutions to \\(ax^2 + bx + c = 0\\) and they are
$$x = {-b \\pm \\sqrt{b^2-4ac} \\over 2a}.$$"""
)
`}]},"link-output":{name:"Link (text URL)",description:"Allow users to see and open content from text links.",type:"link-output",events:[],autoHeight:!0,dashProperties:{minWidth:60,minHeight:30,initialWidth:146,initialHeight:72},pythonAPI:{name:"display_link",params:[{argName:"link_url",description:"The url of the link to display to the user",typeName:"str",typeDescription:["str (URL)"],isKwarg:!1,default:null,dashesInitialValue:'"https://www.abstracloud.com"'},{argName:"link_text",description:'The text to display on the link. Defaults to "Click here".',typeName:"str",isKwarg:!0,default:'"Click here"'},{argName:"same_tab",description:"Whether to open the link in the same tab or not. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"linkText",typeName:"string"},{argName:"linkUrl",typeName:"string"},{argName:"sameTab",typeName:"boolean"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{linkUrl:"https://console.abstracloud.com",linkText:"Abstra Cloud Homepage"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_link",key:"example1",code:`from abstra.forms import display_link

display_link("https://console.abstracloud.com", link_text="Abstra Cloud Homepage")
`}]},"markdown-output":{name:"Markdown",description:"Show a formatted text to the user",type:"markdown-output",autoHeight:!0,events:[],dashProperties:{minWidth:60,minHeight:30,initialWidth:146,initialHeight:72},pythonAPI:{name:"display_markdown",params:[{argName:"text",description:"The formatted text to display to the user",typeName:"str",typeDescription:["str (markdown snippet)"],isKwarg:!1,default:null,dashesInitialValue:'"### Hello World"'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"text",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{text:`
## Let's see some examples 8-)

* 1^th^ H~2~0 

- [ ] Task

* ==Mark==

* [Link](https://www.abstracloud.com/)`},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_markdown",key:"example1",code:`from abstra.forms import display_markdown


display_markdown(
    """
## Let's see some examples 8-)

* 1^th^ H~2~0



- [ ] Task

* ==Mark==

* [Link](https://www.abstracloud.com/)"""
)
`}]},"pandas-output":{name:"Table",description:"Display a pandas dataframe to the user",type:"pandas-output",autoHeight:!1,events:[{key:"row-click",description:"When clicking on a row",payloadSchema:[{key:"row",typeName:"pandas.Series",description:"The row that was clicked"}]},{key:"row-edit",description:"Function or expression to be run when the user edits a cell",payloadSchema:[]},{key:"action-click",description:"Function or expression to be run when the input value changes",payloadSchema:[{key:"action",description:"The action that was clicked",typeName:"str"}]}],dashProperties:{minWidth:200,minHeight:250,initialWidth:500,initialHeight:500},pythonAPI:{name:"display_pandas",params:[{argName:"df",description:"The dataframe to display to the user",typeName:"PandasDataFrame",isKwarg:!1,default:null},{argName:"display_index",description:"Whether to show a index column. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!0,default:null},{argName:"editable",description:"Whether the user will be allowed to edit the cells. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False"},{argName:"actions",description:"Actions that can be triggered by table rows",typeName:"list",typeDescription:["list[str]"],isKwarg:!0,default:"[]"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"table",typeName:"object",properties:[{argName:"data",typeName:"array"},{argName:"schema",typeName:"object",properties:[{argName:"fields",typeName:"array"}]}]},{argName:"displayIndex",typeName:"boolean"},{argName:"label",typeName:"string"},{argName:"editable",typeName:"boolean"},{argName:"actions",typeName:"array"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{table:{schema:{fields:[{name:"Country",type:"string"},{name:"Population",type:"number"}],primaryKey:["Country"]},data:[{Country:"USA",Population:"32,700,000"},{Country:"China",Population:"1,300,000,000"},{Country:"Japan",Population:"126,000,000"}]}},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_pandas",key:"example1",code:`from abstra.forms import display_pandas

display_pandas(df)
`}]},"plotly-output":{name:"Plotly graph",description:"Displays a Plotly figure to the user",type:"plotly-output",events:[],autoHeight:!1,dashProperties:{minWidth:245,minHeight:112,initialWidth:245,initialHeight:112},pythonAPI:{name:"display_plotly",params:[{argName:"fig",description:"The figure to display to the user",typeName:"PlotlyFigure",isKwarg:!1,default:null},{argName:"label",description:"The label to display to the user",typeName:"str",isKwarg:!0,default:null},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"figure",typeName:"object"},{argName:"label",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{figure:{data:[{type:"bar",x:[1,2,3],y:[1,3,2]}],layout:{title:{text:"Bar chart example"}}}},name:"Basic Example",description:"The following example demonstrate some of the available functionality for display_plotly",key:"example1",code:`from abstra.forms import display_plotly
import plotly.graph_objects as go

figure = go.Figure(
    data=[go.Bar(x=[1, 2, 3], y=[1, 3, 2])],
    layout=go.Layout(title=go.layout.Title(text="Bar chart example")),
)

display_plotly(figure)
`}]},"progress-output":{name:"Progress bar",description:"Show a progress bar when loading the app.",type:"progress-output",events:[],autoHeight:!0,dashProperties:{minWidth:60,minHeight:30,initialWidth:300,initialHeight:32},pythonAPI:{name:"display_progress",params:[{argName:"current",description:"The progress being made. Defaults to 50.",typeName:"float",isKwarg:!1,default:"50",dashesInitialValue:"50"},{argName:"total",description:"Total progress. Defaults to 100.",typeName:"float",isKwarg:!1,default:"100",dashesInitialValue:"100"},{argName:"text",description:'The text displayed with this progress step. Defaults to "".',typeName:"str",isKwarg:!0,default:'""'},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"current",typeName:"number"},{argName:"total",typeName:"number"},{argName:"text",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{current:50,total:100},name:"Default behavior",description:"This is what happens when there is no parameter passed",key:"example1",code:`from abstra.forms import display_progress

display_progress()
`},{props:{current:8,total:10,text:"Almost there!"},name:"Custom fields",description:"You can customize the current and total number of steps. Also the message of each step",key:"example2",code:`from time import sleep

for i in range(10):
    display_progress(i, 10, text="Computing values")

    sleep(1)  # Do some computation
`}]},"text-output":{name:"Text display",description:'"Text display" adds textual information into the app.',type:"text-output",autoHeight:!0,events:[],dashProperties:{minWidth:60,minHeight:30,initialWidth:223,initialHeight:112},pythonAPI:{name:"display",params:[{argName:"text",description:"The text to display to the user",typeName:"str",isKwarg:!1,default:null,dashesInitialValue:'"Your text here!"'},{argName:"size",description:"The size of the text: 'small', 'medium', 'large'",typeName:"str",isKwarg:!0,default:"medium"},{argName:"end_program",description:"Whether the program should end after the widget is shown. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"full_width",description:"Whether the input should use full screen width. Defaults to False.",typeName:"bool",isKwarg:!0,default:"False",formOnly:!0},{argName:"button_text",description:"What text to display on the button when the widget is not part of a Page. Defaults to 'Next'.",typeName:"str",isKwarg:!0,default:"Next",formOnly:!0}],returns:[]},brokerAPI:{params:[{argName:"text",typeName:"string"},{argName:"size",typeName:"string"},{argName:"fullWidth",typeName:"boolean"}]},examples:[{props:{text:"Hello world!"},name:"Basic Example",description:"The following example demonstrate some of the available functionality for read_display",key:"example1",code:`from abstra.forms import display

display("Hello world!")
`}]}},f=e=>"type"in e&&e.type in w,E=e=>"type"in e&&e.type in w,q=e=>g.exports.upperFirst(g.exports.camelCase(e)),S=(e,t)=>g.exports.pickBy(e,r=>{const a=t[r.type].pythonAPI.params,i=g.exports.pickBy(r.props,(s,l)=>{const u=a.find(n=>n.argName===l),p=s.trim();return!(!u||p.length===0)});return!a.some(s=>{if(!s.isKwarg&&!(s.argName in i)&&!s.default)return!0})});function U(e,t){const r=(a,i)=>{var o;return((o=a.toLocaleLowerCase().match(new RegExp(i.toLocaleLowerCase().replace(/(\\)/g,"\\\\"),"g")))!=null?o:[]).length/a.length};return t.reduce((a,i)=>a+10*r(e.type,i)+5*r(e.name,i)+1*r(e.description,i),0)}const N=(e,t)=>{for(const r in t){if(r===e)return t[r];const a=t[r];if(f(a))continue;const i=N(e,a.slot);if(i)return i}return null},x=(e,t)=>{for(const r in t){const a=t[r];if(f(a))continue;if(r===e)return a;const i=x(e,a.slot);if(i)return i}return null},C=(e,t)=>N(e,y(t)),B=(e,t)=>{const r=N(e,y(t));if(!r)throw new Error("widget not found");return r.id=e,r},L=(e,t)=>x(e,y(t)),y=e=>e.version==="0.1"?e.widgets:e.slot,R=e=>e.version==="0.1"?"/widgets":"/slot",_="#414a58",K="DM Sans",F="Inter";function W(e){var t,r,a,i,o,s,l,u,p,n,h,m,d,c,b;return{id:e.id,path:e.path,theme:(t=e.workspace.theme)!=null?t:"#FFFFFF",brandName:(r=e.workspace.brand_name)!=null?r:null,title:e.title,isLocal:(a=e.is_local)!=null?a:!1,startMessage:(i=e.start_message)!=null?i:null,endMessage:(o=e.end_message)!=null?o:null,errorMessage:(s=e.error_message)!=null?s:null,timeoutMessage:(l=e.timeout_message)!=null?l:null,startButtonText:(u=e.start_button_text)!=null?u:null,restartButtonText:(p=e.restart_button_text)!=null?p:null,logoUrl:e.workspace.logo_url,mainColor:(n=e.workspace.main_color)!=null?n:_,fontFamily:(h=e.workspace.font_family)!=null?h:K,autoStart:(m=e.auto_start)!=null?m:!1,allowRestart:e.allow_restart,welcomeTitle:(d=e.welcome_title)!=null?d:null,runtimeType:"form",sidebar:(b=(c=e.workspace)==null?void 0:c.sidebar)!=null?b:[]}}function T(e){var t,r,a,i,o,s,l;return{id:e.path,path:e.path,title:e.title,theme:(t=e.workspace.theme)!=null?t:"#FFFFFF",brandName:e.workspace.brand_name,logoUrl:e.workspace.logo_url,mainColor:(r=e.workspace.main_color)!=null?r:_,fontFamily:(a=e.workspace.font_family)!=null?a:F,layout:e.layout,workspaceName:(o=(i=e.workspace)==null?void 0:i.name)!=null?o:"Untitled Workspace",runtimeType:"dash",sidebar:(l=(s=e.workspace)==null?void 0:s.sidebar)!=null?l:[]}}const j=e=>({...e,slot:v(y(e))}),O=e=>{var t,r;return{...e,id:(t=e.id)!=null?t:"",variable:(r=e.variable)!=null?r:null,props:Object.entries(e.props).filter(([,a])=>a.trim()).map(([a])=>a),events:Object.entries(e.events).filter(([,a])=>a.trim()).map(([a])=>a),position:{rowStart:e.rowStart,rowEnd:e.rowEnd,colStart:e.colStart,colEnd:e.colEnd}}},P=e=>({...e,slot:v(e.slot),props:e.props,position:{row:e.row,height:e.height,order:e.order}}),v=e=>{if(!e)throw new Error("Slot is undefined");return Object.keys(e).reduce((t,r)=>{const a=e[r];return f(a)?{...t,[r]:O(a)}:{...t,[r]:P(a)}},{})};async function A(e){const t=await fetch(`/_api/${e}`);if(t.status==404)return null;if(!t.ok)throw new Error(await t.text());const{form:r,dash:a}=await t.json();return{form:r&&W(r),dash:a&&T(a)}}var D={exports:{}};(function(e,t){(function(r,a,i){e.exports=i(),e.exports.default=i()})("slugify",k,function(){var r=JSON.parse(`{"$":"dollar","%":"percent","&":"and","<":"less",">":"greater","|":"or","\xA2":"cent","\xA3":"pound","\xA4":"currency","\xA5":"yen","\xA9":"(c)","\xAA":"a","\xAE":"(r)","\xBA":"o","\xC0":"A","\xC1":"A","\xC2":"A","\xC3":"A","\xC4":"A","\xC5":"A","\xC6":"AE","\xC7":"C","\xC8":"E","\xC9":"E","\xCA":"E","\xCB":"E","\xCC":"I","\xCD":"I","\xCE":"I","\xCF":"I","\xD0":"D","\xD1":"N","\xD2":"O","\xD3":"O","\xD4":"O","\xD5":"O","\xD6":"O","\xD8":"O","\xD9":"U","\xDA":"U","\xDB":"U","\xDC":"U","\xDD":"Y","\xDE":"TH","\xDF":"ss","\xE0":"a","\xE1":"a","\xE2":"a","\xE3":"a","\xE4":"a","\xE5":"a","\xE6":"ae","\xE7":"c","\xE8":"e","\xE9":"e","\xEA":"e","\xEB":"e","\xEC":"i","\xED":"i","\xEE":"i","\xEF":"i","\xF0":"d","\xF1":"n","\xF2":"o","\xF3":"o","\xF4":"o","\xF5":"o","\xF6":"o","\xF8":"o","\xF9":"u","\xFA":"u","\xFB":"u","\xFC":"u","\xFD":"y","\xFE":"th","\xFF":"y","\u0100":"A","\u0101":"a","\u0102":"A","\u0103":"a","\u0104":"A","\u0105":"a","\u0106":"C","\u0107":"c","\u010C":"C","\u010D":"c","\u010E":"D","\u010F":"d","\u0110":"DJ","\u0111":"dj","\u0112":"E","\u0113":"e","\u0116":"E","\u0117":"e","\u0118":"e","\u0119":"e","\u011A":"E","\u011B":"e","\u011E":"G","\u011F":"g","\u0122":"G","\u0123":"g","\u0128":"I","\u0129":"i","\u012A":"i","\u012B":"i","\u012E":"I","\u012F":"i","\u0130":"I","\u0131":"i","\u0136":"k","\u0137":"k","\u013B":"L","\u013C":"l","\u013D":"L","\u013E":"l","\u0141":"L","\u0142":"l","\u0143":"N","\u0144":"n","\u0145":"N","\u0146":"n","\u0147":"N","\u0148":"n","\u014C":"O","\u014D":"o","\u0150":"O","\u0151":"o","\u0152":"OE","\u0153":"oe","\u0154":"R","\u0155":"r","\u0158":"R","\u0159":"r","\u015A":"S","\u015B":"s","\u015E":"S","\u015F":"s","\u0160":"S","\u0161":"s","\u0162":"T","\u0163":"t","\u0164":"T","\u0165":"t","\u0168":"U","\u0169":"u","\u016A":"u","\u016B":"u","\u016E":"U","\u016F":"u","\u0170":"U","\u0171":"u","\u0172":"U","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017A":"z","\u017B":"Z","\u017C":"z","\u017D":"Z","\u017E":"z","\u018F":"E","\u0192":"f","\u01A0":"O","\u01A1":"o","\u01AF":"U","\u01B0":"u","\u01C8":"LJ","\u01C9":"lj","\u01CB":"NJ","\u01CC":"nj","\u0218":"S","\u0219":"s","\u021A":"T","\u021B":"t","\u0259":"e","\u02DA":"o","\u0386":"A","\u0388":"E","\u0389":"H","\u038A":"I","\u038C":"O","\u038E":"Y","\u038F":"W","\u0390":"i","\u0391":"A","\u0392":"B","\u0393":"G","\u0394":"D","\u0395":"E","\u0396":"Z","\u0397":"H","\u0398":"8","\u0399":"I","\u039A":"K","\u039B":"L","\u039C":"M","\u039D":"N","\u039E":"3","\u039F":"O","\u03A0":"P","\u03A1":"R","\u03A3":"S","\u03A4":"T","\u03A5":"Y","\u03A6":"F","\u03A7":"X","\u03A8":"PS","\u03A9":"W","\u03AA":"I","\u03AB":"Y","\u03AC":"a","\u03AD":"e","\u03AE":"h","\u03AF":"i","\u03B0":"y","\u03B1":"a","\u03B2":"b","\u03B3":"g","\u03B4":"d","\u03B5":"e","\u03B6":"z","\u03B7":"h","\u03B8":"8","\u03B9":"i","\u03BA":"k","\u03BB":"l","\u03BC":"m","\u03BD":"n","\u03BE":"3","\u03BF":"o","\u03C0":"p","\u03C1":"r","\u03C2":"s","\u03C3":"s","\u03C4":"t","\u03C5":"y","\u03C6":"f","\u03C7":"x","\u03C8":"ps","\u03C9":"w","\u03CA":"i","\u03CB":"y","\u03CC":"o","\u03CD":"y","\u03CE":"w","\u0401":"Yo","\u0402":"DJ","\u0404":"Ye","\u0406":"I","\u0407":"Yi","\u0408":"J","\u0409":"LJ","\u040A":"NJ","\u040B":"C","\u040F":"DZ","\u0410":"A","\u0411":"B","\u0412":"V","\u0413":"G","\u0414":"D","\u0415":"E","\u0416":"Zh","\u0417":"Z","\u0418":"I","\u0419":"J","\u041A":"K","\u041B":"L","\u041C":"M","\u041D":"N","\u041E":"O","\u041F":"P","\u0420":"R","\u0421":"S","\u0422":"T","\u0423":"U","\u0424":"F","\u0425":"H","\u0426":"C","\u0427":"Ch","\u0428":"Sh","\u0429":"Sh","\u042A":"U","\u042B":"Y","\u042C":"","\u042D":"E","\u042E":"Yu","\u042F":"Ya","\u0430":"a","\u0431":"b","\u0432":"v","\u0433":"g","\u0434":"d","\u0435":"e","\u0436":"zh","\u0437":"z","\u0438":"i","\u0439":"j","\u043A":"k","\u043B":"l","\u043C":"m","\u043D":"n","\u043E":"o","\u043F":"p","\u0440":"r","\u0441":"s","\u0442":"t","\u0443":"u","\u0444":"f","\u0445":"h","\u0446":"c","\u0447":"ch","\u0448":"sh","\u0449":"sh","\u044A":"u","\u044B":"y","\u044C":"","\u044D":"e","\u044E":"yu","\u044F":"ya","\u0451":"yo","\u0452":"dj","\u0454":"ye","\u0456":"i","\u0457":"yi","\u0458":"j","\u0459":"lj","\u045A":"nj","\u045B":"c","\u045D":"u","\u045F":"dz","\u0490":"G","\u0491":"g","\u0492":"GH","\u0493":"gh","\u049A":"KH","\u049B":"kh","\u04A2":"NG","\u04A3":"ng","\u04AE":"UE","\u04AF":"ue","\u04B0":"U","\u04B1":"u","\u04BA":"H","\u04BB":"h","\u04D8":"AE","\u04D9":"ae","\u04E8":"OE","\u04E9":"oe","\u0531":"A","\u0532":"B","\u0533":"G","\u0534":"D","\u0535":"E","\u0536":"Z","\u0537":"E'","\u0538":"Y'","\u0539":"T'","\u053A":"JH","\u053B":"I","\u053C":"L","\u053D":"X","\u053E":"C'","\u053F":"K","\u0540":"H","\u0541":"D'","\u0542":"GH","\u0543":"TW","\u0544":"M","\u0545":"Y","\u0546":"N","\u0547":"SH","\u0549":"CH","\u054A":"P","\u054B":"J","\u054C":"R'","\u054D":"S","\u054E":"V","\u054F":"T","\u0550":"R","\u0551":"C","\u0553":"P'","\u0554":"Q'","\u0555":"O''","\u0556":"F","\u0587":"EV","\u0621":"a","\u0622":"aa","\u0623":"a","\u0624":"u","\u0625":"i","\u0626":"e","\u0627":"a","\u0628":"b","\u0629":"h","\u062A":"t","\u062B":"th","\u062C":"j","\u062D":"h","\u062E":"kh","\u062F":"d","\u0630":"th","\u0631":"r","\u0632":"z","\u0633":"s","\u0634":"sh","\u0635":"s","\u0636":"dh","\u0637":"t","\u0638":"z","\u0639":"a","\u063A":"gh","\u0641":"f","\u0642":"q","\u0643":"k","\u0644":"l","\u0645":"m","\u0646":"n","\u0647":"h","\u0648":"w","\u0649":"a","\u064A":"y","\u064B":"an","\u064C":"on","\u064D":"en","\u064E":"a","\u064F":"u","\u0650":"e","\u0652":"","\u0660":"0","\u0661":"1","\u0662":"2","\u0663":"3","\u0664":"4","\u0665":"5","\u0666":"6","\u0667":"7","\u0668":"8","\u0669":"9","\u067E":"p","\u0686":"ch","\u0698":"zh","\u06A9":"k","\u06AF":"g","\u06CC":"y","\u06F0":"0","\u06F1":"1","\u06F2":"2","\u06F3":"3","\u06F4":"4","\u06F5":"5","\u06F6":"6","\u06F7":"7","\u06F8":"8","\u06F9":"9","\u0E3F":"baht","\u10D0":"a","\u10D1":"b","\u10D2":"g","\u10D3":"d","\u10D4":"e","\u10D5":"v","\u10D6":"z","\u10D7":"t","\u10D8":"i","\u10D9":"k","\u10DA":"l","\u10DB":"m","\u10DC":"n","\u10DD":"o","\u10DE":"p","\u10DF":"zh","\u10E0":"r","\u10E1":"s","\u10E2":"t","\u10E3":"u","\u10E4":"f","\u10E5":"k","\u10E6":"gh","\u10E7":"q","\u10E8":"sh","\u10E9":"ch","\u10EA":"ts","\u10EB":"dz","\u10EC":"ts","\u10ED":"ch","\u10EE":"kh","\u10EF":"j","\u10F0":"h","\u1E62":"S","\u1E63":"s","\u1E80":"W","\u1E81":"w","\u1E82":"W","\u1E83":"w","\u1E84":"W","\u1E85":"w","\u1E9E":"SS","\u1EA0":"A","\u1EA1":"a","\u1EA2":"A","\u1EA3":"a","\u1EA4":"A","\u1EA5":"a","\u1EA6":"A","\u1EA7":"a","\u1EA8":"A","\u1EA9":"a","\u1EAA":"A","\u1EAB":"a","\u1EAC":"A","\u1EAD":"a","\u1EAE":"A","\u1EAF":"a","\u1EB0":"A","\u1EB1":"a","\u1EB2":"A","\u1EB3":"a","\u1EB4":"A","\u1EB5":"a","\u1EB6":"A","\u1EB7":"a","\u1EB8":"E","\u1EB9":"e","\u1EBA":"E","\u1EBB":"e","\u1EBC":"E","\u1EBD":"e","\u1EBE":"E","\u1EBF":"e","\u1EC0":"E","\u1EC1":"e","\u1EC2":"E","\u1EC3":"e","\u1EC4":"E","\u1EC5":"e","\u1EC6":"E","\u1EC7":"e","\u1EC8":"I","\u1EC9":"i","\u1ECA":"I","\u1ECB":"i","\u1ECC":"O","\u1ECD":"o","\u1ECE":"O","\u1ECF":"o","\u1ED0":"O","\u1ED1":"o","\u1ED2":"O","\u1ED3":"o","\u1ED4":"O","\u1ED5":"o","\u1ED6":"O","\u1ED7":"o","\u1ED8":"O","\u1ED9":"o","\u1EDA":"O","\u1EDB":"o","\u1EDC":"O","\u1EDD":"o","\u1EDE":"O","\u1EDF":"o","\u1EE0":"O","\u1EE1":"o","\u1EE2":"O","\u1EE3":"o","\u1EE4":"U","\u1EE5":"u","\u1EE6":"U","\u1EE7":"u","\u1EE8":"U","\u1EE9":"u","\u1EEA":"U","\u1EEB":"u","\u1EEC":"U","\u1EED":"u","\u1EEE":"U","\u1EEF":"u","\u1EF0":"U","\u1EF1":"u","\u1EF2":"Y","\u1EF3":"y","\u1EF4":"Y","\u1EF5":"y","\u1EF6":"Y","\u1EF7":"y","\u1EF8":"Y","\u1EF9":"y","\u2013":"-","\u2018":"'","\u2019":"'","\u201C":"\\"","\u201D":"\\"","\u201E":"\\"","\u2020":"+","\u2022":"*","\u2026":"...","\u20A0":"ecu","\u20A2":"cruzeiro","\u20A3":"french franc","\u20A4":"lira","\u20A5":"mill","\u20A6":"naira","\u20A7":"peseta","\u20A8":"rupee","\u20A9":"won","\u20AA":"new shequel","\u20AB":"dong","\u20AC":"euro","\u20AD":"kip","\u20AE":"tugrik","\u20AF":"drachma","\u20B0":"penny","\u20B1":"peso","\u20B2":"guarani","\u20B3":"austral","\u20B4":"hryvnia","\u20B5":"cedi","\u20B8":"kazakhstani tenge","\u20B9":"indian rupee","\u20BA":"turkish lira","\u20BD":"russian ruble","\u20BF":"bitcoin","\u2120":"sm","\u2122":"tm","\u2202":"d","\u2206":"delta","\u2211":"sum","\u221E":"infinity","\u2665":"love","\u5143":"yuan","\u5186":"yen","\uFDFC":"rial","\uFEF5":"laa","\uFEF7":"laa","\uFEF9":"lai","\uFEFB":"la"}`),a=JSON.parse('{"bg":{"\u0419":"Y","\u0426":"Ts","\u0429":"Sht","\u042A":"A","\u042C":"Y","\u0439":"y","\u0446":"ts","\u0449":"sht","\u044A":"a","\u044C":"y"},"de":{"\xC4":"AE","\xE4":"ae","\xD6":"OE","\xF6":"oe","\xDC":"UE","\xFC":"ue","\xDF":"ss","%":"prozent","&":"und","|":"oder","\u2211":"summe","\u221E":"unendlich","\u2665":"liebe"},"es":{"%":"por ciento","&":"y","<":"menor que",">":"mayor que","|":"o","\xA2":"centavos","\xA3":"libras","\xA4":"moneda","\u20A3":"francos","\u2211":"suma","\u221E":"infinito","\u2665":"amor"},"fr":{"%":"pourcent","&":"et","<":"plus petit",">":"plus grand","|":"ou","\xA2":"centime","\xA3":"livre","\xA4":"devise","\u20A3":"franc","\u2211":"somme","\u221E":"infini","\u2665":"amour"},"pt":{"%":"porcento","&":"e","<":"menor",">":"maior","|":"ou","\xA2":"centavo","\u2211":"soma","\xA3":"libra","\u221E":"infinito","\u2665":"amor"},"uk":{"\u0418":"Y","\u0438":"y","\u0419":"Y","\u0439":"y","\u0426":"Ts","\u0446":"ts","\u0425":"Kh","\u0445":"kh","\u0429":"Shch","\u0449":"shch","\u0413":"H","\u0433":"h"},"vi":{"\u0110":"D","\u0111":"d"},"da":{"\xD8":"OE","\xF8":"oe","\xC5":"AA","\xE5":"aa","%":"procent","&":"og","|":"eller","$":"dollar","<":"mindre end",">":"st\xF8rre end"},"nb":{"&":"og","\xC5":"AA","\xC6":"AE","\xD8":"OE","\xE5":"aa","\xE6":"ae","\xF8":"oe"},"it":{"&":"e"},"nl":{"&":"en"},"sv":{"&":"och","\xC5":"AA","\xC4":"AE","\xD6":"OE","\xE5":"aa","\xE4":"ae","\xF6":"oe"}}');function i(o,s){if(typeof o!="string")throw new Error("slugify: string argument expected");s=typeof s=="string"?{replacement:s}:s||{};var l=a[s.locale]||{},u=s.replacement===void 0?"-":s.replacement,p=s.trim===void 0?!0:s.trim,n=o.normalize().split("").reduce(function(h,m){var d=l[m]||r[m]||m;return d===u&&(d=" "),h+d.replace(s.remove||/[^\w\s$*_+~.()'"!\-:@]+/g,"")},"");return s.strict&&(n=n.replace(/[^A-Za-z0-9\s]/g,"")),p&&(n=n.trim()),n=n.replace(/\s+/g,u),s.lower&&(n=n.toLowerCase()),n}return i.extend=function(o){Object.assign(r,o)},i})})(D);const M=D.exports,V=()=>{const{hostname:e}=window.location;return e.includes("abstra.run")?null:e.startsWith("localhost")?{}.VITE_CNAME?{}.VITE_CNAME:null:e};function z(e,t){const r=document,a=e.matched.slice().reverse().find(o=>o.meta&&o.meta.title),i=t.matched.slice().reverse().find(o=>o.meta&&o.meta.metaTags);a?r.title=a.meta.title:i&&(r.title=i.meta.title)}async function I(e){const t=await A(e);if(t!=null&&t.dash)return"dashes";if(t!=null&&t.form)return"forms";throw new Error("Invalid runtime")}async function Y(e,t,r,a={}){if(r.startsWith("http")){const i=new URLSearchParams(a),o=new URL(r);o.search=i.toString(),window.location.href=o.toString()}else{const i=r.replace(/\/$/,""),o=await I(i);if(e==="player")t.push({path:r,query:a});else if(e==="editor"&&o==="dashes")t.push({name:"dashEditor",params:{dashPath:i},query:a});else if(e==="editor"&&o==="forms")t.push({name:"formEditor",params:{formPath:i},query:a});else if(e==="preview"&&o==="dashes")t.push({name:"dashPreview",params:{dashPath:i},query:a});else if(e==="preview"&&o==="forms")t.push({name:"formPreview",params:{formPath:i},query:a});else throw new Error("Invalid routing")}}export{q as a,B as b,y as c,j as d,R as e,N as f,V as g,L as h,f as i,C as j,S as k,E as l,A as m,M as n,Y as r,U as s,z as u,w};
//# sourceMappingURL=index.2b5138c8.js.map
