ory_client/models/ui_node_attributes.rs
1/*
2 * Ory APIs
3 *
4 * # Introduction Documentation for all public and administrative Ory APIs. Administrative APIs can only be accessed with a valid Personal Access Token. Public APIs are mostly used in browsers. ## SDKs This document describes the APIs available in the Ory Network. The APIs are available as SDKs for the following languages: | Language | Download SDK | Documentation | | -------------- | ---------------------------------------------------------------- | ------------------------------------------------------------------------------------ | | Dart | [pub.dev](https://pub.dev/packages/ory_client) | [README](https://github.com/ory/sdk/blob/master/clients/client/dart/README.md) | | .NET | [nuget.org](https://www.nuget.org/packages/Ory.Client/) | [README](https://github.com/ory/sdk/blob/master/clients/client/dotnet/README.md) | | Elixir | [hex.pm](https://hex.pm/packages/ory_client) | [README](https://github.com/ory/sdk/blob/master/clients/client/elixir/README.md) | | Go | [github.com](https://github.com/ory/client-go) | [README](https://github.com/ory/sdk/blob/master/clients/client/go/README.md) | | Java | [maven.org](https://search.maven.org/artifact/sh.ory/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/java/README.md) | | JavaScript | [npmjs.com](https://www.npmjs.com/package/@ory/client) | [README](https://github.com/ory/sdk/blob/master/clients/client/typescript/README.md) | | JavaScript (With fetch) | [npmjs.com](https://www.npmjs.com/package/@ory/client-fetch) | [README](https://github.com/ory/sdk/blob/master/clients/client/typescript-fetch/README.md) | | PHP | [packagist.org](https://packagist.org/packages/ory/client) | [README](https://github.com/ory/sdk/blob/master/clients/client/php/README.md) | | Python | [pypi.org](https://pypi.org/project/ory-client/) | [README](https://github.com/ory/sdk/blob/master/clients/client/python/README.md) | | Ruby | [rubygems.org](https://rubygems.org/gems/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/ruby/README.md) | | Rust | [crates.io](https://crates.io/crates/ory-client) | [README](https://github.com/ory/sdk/blob/master/clients/client/rust/README.md) |
5 *
6 * The version of the OpenAPI document: v1.22.92
7 * Contact: support@ory.sh
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
15#[serde(tag = "node_type")]
16pub enum UiNodeAttributes {
17 #[serde(rename="input")]
18 Input(Box<models::UiNodeInputAttributes>),
19 #[serde(rename="text")]
20 Text(Box<models::UiNodeTextAttributes>),
21 #[serde(rename="img")]
22 Img(Box<models::UiNodeImageAttributes>),
23 #[serde(rename="a")]
24 A(Box<models::UiNodeAnchorAttributes>),
25 #[serde(rename="script")]
26 Script(Box<models::UiNodeScriptAttributes>),
27 #[serde(rename="div")]
28 Div(Box<models::UiNodeDivisionAttributes>),
29}
30
31impl Default for UiNodeAttributes {
32 fn default() -> Self {
33 Self::Input(Default::default())
34 }
35}
36
37/// The autocomplete attribute for the input. email InputAttributeAutocompleteEmail tel InputAttributeAutocompleteTel url InputAttributeAutocompleteUrl current-password InputAttributeAutocompleteCurrentPassword new-password InputAttributeAutocompleteNewPassword one-time-code InputAttributeAutocompleteOneTimeCode username InputAttributeAutocompleteUsername username webauthn InputAttributeAutocompleteUsernameWebauthn
38#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
39pub enum AutocompleteEnum {
40 #[serde(rename = "email")]
41 Email,
42 #[serde(rename = "tel")]
43 Tel,
44 #[serde(rename = "url")]
45 Url,
46 #[serde(rename = "current-password")]
47 CurrentPassword,
48 #[serde(rename = "new-password")]
49 NewPassword,
50 #[serde(rename = "one-time-code")]
51 OneTimeCode,
52 #[serde(rename = "username")]
53 Username,
54 #[serde(rename = "username webauthn")]
55 UsernameWebauthn,
56}
57
58impl Default for AutocompleteEnum {
59 fn default() -> AutocompleteEnum {
60 Self::Email
61 }
62}
63/// The inputmode attribute for the input, which hints at the virtual keyboard to show. numeric InputAttributeInputModeNumeric text InputAttributeInputModeText
64#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
65pub enum InputmodeEnum {
66 #[serde(rename = "numeric")]
67 Numeric,
68 #[serde(rename = "text")]
69 Text,
70}
71
72impl Default for InputmodeEnum {
73 fn default() -> InputmodeEnum {
74 Self::Numeric
75 }
76}
77/// OnClickTrigger may contain a WebAuthn trigger which should be executed on click. The trigger maps to a JavaScript function provided by Ory, which triggers actions such as PassKey registration or login. oryWebAuthnRegistration WebAuthnTriggersWebAuthnRegistration oryWebAuthnLogin WebAuthnTriggersWebAuthnLogin oryPasskeyLogin WebAuthnTriggersPasskeyLogin oryPasskeyLoginAutocompleteInit WebAuthnTriggersPasskeyLoginAutocompleteInit oryPasskeyRegistration WebAuthnTriggersPasskeyRegistration oryPasskeySettingsRegistration WebAuthnTriggersPasskeySettingsRegistration
78#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
79pub enum OnclickTriggerEnum {
80 #[serde(rename = "oryWebAuthnRegistration")]
81 OryWebAuthnRegistration,
82 #[serde(rename = "oryWebAuthnLogin")]
83 OryWebAuthnLogin,
84 #[serde(rename = "oryPasskeyLogin")]
85 OryPasskeyLogin,
86 #[serde(rename = "oryPasskeyLoginAutocompleteInit")]
87 OryPasskeyLoginAutocompleteInit,
88 #[serde(rename = "oryPasskeyRegistration")]
89 OryPasskeyRegistration,
90 #[serde(rename = "oryPasskeySettingsRegistration")]
91 OryPasskeySettingsRegistration,
92}
93
94impl Default for OnclickTriggerEnum {
95 fn default() -> OnclickTriggerEnum {
96 Self::OryWebAuthnRegistration
97 }
98}
99/// OnLoadTrigger may contain a WebAuthn trigger which should be executed on load. The trigger maps to a JavaScript function provided by Ory, which triggers actions such as PassKey registration or login. oryWebAuthnRegistration WebAuthnTriggersWebAuthnRegistration oryWebAuthnLogin WebAuthnTriggersWebAuthnLogin oryPasskeyLogin WebAuthnTriggersPasskeyLogin oryPasskeyLoginAutocompleteInit WebAuthnTriggersPasskeyLoginAutocompleteInit oryPasskeyRegistration WebAuthnTriggersPasskeyRegistration oryPasskeySettingsRegistration WebAuthnTriggersPasskeySettingsRegistration
100#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
101pub enum OnloadTriggerEnum {
102 #[serde(rename = "oryWebAuthnRegistration")]
103 OryWebAuthnRegistration,
104 #[serde(rename = "oryWebAuthnLogin")]
105 OryWebAuthnLogin,
106 #[serde(rename = "oryPasskeyLogin")]
107 OryPasskeyLogin,
108 #[serde(rename = "oryPasskeyLoginAutocompleteInit")]
109 OryPasskeyLoginAutocompleteInit,
110 #[serde(rename = "oryPasskeyRegistration")]
111 OryPasskeyRegistration,
112 #[serde(rename = "oryPasskeySettingsRegistration")]
113 OryPasskeySettingsRegistration,
114}
115
116impl Default for OnloadTriggerEnum {
117 fn default() -> OnloadTriggerEnum {
118 Self::OryWebAuthnRegistration
119 }
120}
121