Update styles (#11342)
This commit is contained in:
parent
0cc2513226
commit
b57ebe0074
3 changed files with 55 additions and 63 deletions
|
|
@ -145,8 +145,8 @@ label {
|
|||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--su-4);
|
||||
padding-top: var(--su-4);
|
||||
padding-bottom: var(--su-4);
|
||||
padding-top: var(--su-6);
|
||||
padding-bottom: var(--su-2);
|
||||
}
|
||||
|
||||
.admin-config-checkmark {
|
||||
|
|
|
|||
|
|
@ -1,54 +1,48 @@
|
|||
<div class="config-authentication__item">
|
||||
<div class="config-authentication__item--container">
|
||||
<div class="config-authentication__item--body">
|
||||
<fieldset class="config-authentication-form">
|
||||
<div class="crayons-field">
|
||||
<%= admin_config_label :"#{provider.provider_name}_key" %>
|
||||
<p class="crayons-field__description">
|
||||
<%= Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_key"][:description] %>
|
||||
</p>
|
||||
<%= f.text_field :"#{provider.provider_name}_key",
|
||||
class: "crayons-textfield",
|
||||
value: SiteConfig.public_send("#{provider.provider_name}_key"),
|
||||
placeholder: Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_key"][:placeholder] %>
|
||||
</div>
|
||||
<div class="crayons-field">
|
||||
<%= admin_config_label :"#{provider.provider_name}_secret" %>
|
||||
<p class="crayons-field__description">
|
||||
<%= Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_secret"][:description] %>
|
||||
<p>
|
||||
<%= f.text_field :"#{provider.provider_name}_secret",
|
||||
class: "crayons-textfield",
|
||||
value: SiteConfig.public_send("#{provider.provider_name}_secret"),
|
||||
placeholder: Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_secret"][:placeholder] %>
|
||||
</div>
|
||||
<div class="mt-6">
|
||||
<% if authentication_enabled_providers.include?(provider) %>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--danger <%= tooltip_class_on_auth_provider_disablebtn %>"
|
||||
data-action="click->config#activateAuthProviderModal"
|
||||
data-tooltip="<%= tooltip_text_email_or_auth_provider_btns %>"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-auth-provider-official="<%= provider.official_name %>"
|
||||
<%= disabled_attr_on_auth_rpovider_disablebtn %>>
|
||||
Disable
|
||||
</button>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--secondary"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-action="click->config#hideAuthProviderSettings">
|
||||
Close
|
||||
</button>
|
||||
<% else %>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--secondary"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-action="click->config#disableAuthProvider">
|
||||
Undo
|
||||
</button>
|
||||
<% end %>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<fieldset class="config-authentication-form">
|
||||
<div class="crayons-field">
|
||||
<%= admin_config_label :"#{provider.provider_name}_key" %>
|
||||
<p class="crayons-field__description">
|
||||
<%= Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_key"][:description] %>
|
||||
</p>
|
||||
<%= f.text_field :"#{provider.provider_name}_key",
|
||||
class: "crayons-textfield",
|
||||
value: SiteConfig.public_send("#{provider.provider_name}_key"),
|
||||
placeholder: Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_key"][:placeholder] %>
|
||||
</div>
|
||||
<div class="crayons-field">
|
||||
<%= admin_config_label :"#{provider.provider_name}_secret" %>
|
||||
<p class="crayons-field__description">
|
||||
<%= Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_secret"][:description] %>
|
||||
<p>
|
||||
<%= f.text_field :"#{provider.provider_name}_secret",
|
||||
class: "crayons-textfield",
|
||||
value: SiteConfig.public_send("#{provider.provider_name}_secret"),
|
||||
placeholder: Constants::SiteConfig::DETAILS[:"#{provider.provider_name}_secret"][:placeholder] %>
|
||||
</div>
|
||||
<div class="flex gap-2">
|
||||
<% if authentication_enabled_providers.include?(provider) %>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--danger <%= tooltip_class_on_auth_provider_disablebtn %>"
|
||||
data-action="click->config#activateAuthProviderModal"
|
||||
data-tooltip="<%= tooltip_text_email_or_auth_provider_btns %>"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-auth-provider-official="<%= provider.official_name %>"
|
||||
<%= disabled_attr_on_auth_rpovider_disablebtn %>>
|
||||
Disable
|
||||
</button>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--secondary"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-action="click->config#hideAuthProviderSettings">
|
||||
Close
|
||||
</button>
|
||||
<% else %>
|
||||
<button
|
||||
class="crayons-btn crayons-btn--secondary"
|
||||
data-auth-provider="<%= provider.provider_name %>"
|
||||
data-action="click->config#disableAuthProvider">
|
||||
Undo
|
||||
</button>
|
||||
<% end %>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
|
|
|||
|
|
@ -270,7 +270,7 @@
|
|||
</figure>
|
||||
<div class="config-authentication__item--container">
|
||||
<div
|
||||
class="config-authentication__item mb-0 flex items-baseline justify-between <%= tooltip_class_on_auth_provider_enablebtn %>"
|
||||
class="flex items-center justify-between <%= tooltip_class_on_auth_provider_enablebtn %>"
|
||||
data-tooltip="<%= tooltip_text_email_or_auth_provider_btns %>">
|
||||
<div class="config-authentication__item--label">
|
||||
<p class="crayons-field__label <%= authentication_enabled_providers.include?(provider) ? "pb-0" : "" %>">
|
||||
|
|
@ -295,13 +295,11 @@
|
|||
</button>
|
||||
</div>
|
||||
<div id="<%= provider.provider_name %>-auth-settings" class="config-authentication__item--body hidden">
|
||||
<fieldset class="config-authentication-form">
|
||||
<%= render partial: "auth_provider_settings",
|
||||
locals: {
|
||||
f: f,
|
||||
provider: provider
|
||||
} %>
|
||||
</fieldset>
|
||||
<%= render partial: "auth_provider_settings",
|
||||
locals: {
|
||||
f: f,
|
||||
provider: provider
|
||||
} %>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue