5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-22 19:16:23 +00:00

fix: todos los botones son secundarios

closes #14967
This commit is contained in:
f 2024-01-12 14:11:29 -03:00
parent f8a46d6459
commit 56e4684ef1
No known key found for this signature in database
27 changed files with 106 additions and 91 deletions

View file

@ -29,11 +29,6 @@ $sizes: (
"70ch": 70ch, "70ch": 70ch,
); );
.btn {
background-color: var(--foreground);
color: var(--background);
}
@import "bootstrap"; @import "bootstrap";
@import "editor"; @import "editor";
@ -195,7 +190,7 @@ fieldset {
&[type=button] { &[type=button] {
@extend .btn; @extend .btn;
@extend .btn-info; @extend .btn-secondary;
@extend .m-0; @extend .m-0;
} }
} }
@ -209,8 +204,6 @@ svg {
} }
.btn { .btn {
border: none;
border-radius: 0;
margin-right: 0.3rem; margin-right: 0.3rem;
margin-bottom: 0.3rem; margin-bottom: 0.3rem;
@ -246,7 +239,7 @@ svg {
color: $magenta; color: $magenta;
} }
.btn { .btn-secondary {
background-color: $white; background-color: $white;
color: $black; color: $black;
border: none; border: none;

View file

@ -7,3 +7,22 @@ $cyan: #13fefe;
--background: #{$black}; --background: #{$black};
--color: #{$cyan}; --color: #{$cyan};
} }
.btn-secondary {
background-color: $white;
color: $black;
border: none;
&:hover {
color: $black;
background-color: $cyan;
}
&:active {
background-color: $cyan;
}
&:focus {
box-shadow: 0 0 0 0.2rem $cyan;
}
}

View file

@ -25,4 +25,4 @@
class: 'form-control' class: 'form-control'
.form-group .form-group
= f.submit t('.submit'), class: 'btn btn-lg btn-block' = f.submit t('.submit'), class: 'btn btn-secondary btn-lg btn-block'

View file

@ -30,5 +30,5 @@
placeholder: t('activerecord.attributes.usuarie.email') placeholder: t('activerecord.attributes.usuarie.email')
.actions .actions
= f.submit t('.resend_confirmation_instructions'), = f.submit t('.resend_confirmation_instructions'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -32,4 +32,4 @@
placeholder: t('activerecord.attributes.usuarie.password') placeholder: t('activerecord.attributes.usuarie.password')
.actions .actions
= f.submit t('devise.invitations.edit.submit_button'), = f.submit t('devise.invitations.edit.submit_button'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'

View file

@ -16,4 +16,4 @@
= f.text_field field, class: 'form-control' = f.text_field field, class: 'form-control'
.actions .actions
= f.submit t('devise.invitations.new.submit_button'), = f.submit t('devise.invitations.new.submit_button'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'

View file

@ -39,6 +39,6 @@
.actions .actions
= f.submit t('.change_my_password'), = f.submit t('.change_my_password'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -20,5 +20,5 @@
placeholder: t('activerecord.attributes.usuarie.email') placeholder: t('activerecord.attributes.usuarie.email')
.actions .actions
= f.submit t('.send_me_reset_password_instructions'), = f.submit t('.send_me_reset_password_instructions'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -55,7 +55,7 @@
= t('.we_need_your_current_password_to_confirm_your_changes') = t('.we_need_your_current_password_to_confirm_your_changes')
.actions .actions
= f.submit t('.update'), = f.submit t('.update'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
%hr/ %hr/
.sr-only .sr-only
@ -63,4 +63,4 @@
= button_to t('.cancel_my_account'), = button_to t('.cancel_my_account'),
registration_path(resource_name), registration_path(resource_name),
data: { confirm: t('.are_you_sure') }, data: { confirm: t('.are_you_sure') },
method: :delete, class: 'btn btn-block' method: :delete, class: 'btn btn-secondary btn-block'

View file

@ -56,6 +56,6 @@
.actions .actions
= f.submit t('.sign_up'), = f.submit t('.sign_up'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -35,5 +35,5 @@
remember_for: distance_of_time_in_words(Usuarie.remember_for)) remember_for: distance_of_time_in_words(Usuarie.remember_for))
.actions .actions
= f.submit t('.sign_in'), = f.submit t('.sign_in'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -20,5 +20,5 @@
placeholder: t('activerecord.attributes.usuarie.email') placeholder: t('activerecord.attributes.usuarie.email')
.actions .actions
= f.submit t('.resend_unlock_instructions'), = f.submit t('.resend_unlock_instructions'),
class: 'btn btn-lg btn-block' class: 'btn btn-secondary btn-lg btn-block'
= render 'devise/shared/links' = render 'devise/shared/links'

View file

@ -11,7 +11,7 @@
= select_tag 'to', = select_tag 'to',
options_for_select(@options, @lang_to), options_for_select(@options, @lang_to),
class: 'form-control' class: 'form-control'
= submit_tag t('i18n.translate'), class: 'btn', name: nil = submit_tag t('i18n.translate'), class: 'btn btn-secondary', name: nil
- else - else
= t('i18n.translating.from') = t('i18n.translating.from')
= select_tag 'from', = select_tag 'from',
@ -21,7 +21,7 @@
= select_tag 'to', = select_tag 'to',
options_for_select(@options, @lang_to), options_for_select(@options, @lang_to),
class: 'form-control' class: 'form-control'
= submit_tag t('i18n.change'), class: 'btn', name: nil = submit_tag t('i18n.change'), class: 'btn btn-secondary', name: nil
= render 'layouts/help', help: t('help.i18n.index') = render 'layouts/help', help: t('help.i18n.index')
@ -33,16 +33,16 @@
= hidden_field 'i18n', 'lang_to', value: @lang_to = hidden_field 'i18n', 'lang_to', value: @lang_to
.form-group .form-group
.dropdown.inline .dropdown.inline
%button.btn.dropdown-toggle{type: 'button', %button.btn.btn-secondary.dropdown-toggle{type: 'button',
data: { toggle: 'dropdown' }, data: { toggle: 'dropdown' },
aria: { haspopup: 'true', expanded: 'false' }} aria: { haspopup: 'true', expanded: 'false' }}
= t('i18n.jump') = t('i18n.jump')
.dropdown-menu{aria: { labelledby: t('i18n.jump') }} .dropdown-menu{aria: { labelledby: t('i18n.jump') }}
- @site.data.dig(@lang_from).each_pair do |section, content| - @site.data.dig(@lang_from).each_pair do |section, content|
%a.dropdown-item{href: "##{section}"}= t("help.i18n.#{section}") %a.dropdown-item{href: "##{section}"}= t("help.i18n.#{section}")
= submit_tag t('i18n.save'), class: 'btn' = submit_tag t('i18n.save'), class: 'btn btn-secondary'
= render 'i18n/recursive', data: @site.data.dig(@lang_from), superkeys: [] = render 'i18n/recursive', data: @site.data.dig(@lang_from), superkeys: []
.form-group .form-group
= submit_tag t('i18n.save'), class: 'btn' = submit_tag t('i18n.save'), class: 'btn btn-secondary'

View file

@ -17,15 +17,15 @@
- if @site&.tienda? - if @site&.tienda?
%li.nav-item %li.nav-item
= link_to t('.tienda'), @site.tienda_url, = link_to t('.tienda'), @site.tienda_url,
role: 'button', class: 'btn' role: 'button', class: 'btn btn-secondary'
%li.nav-item %li.nav-item
= link_to t('.contact_us'), t('.contact_us_href'), = link_to t('.contact_us'), t('.contact_us_href'),
class: 'btn', rel: 'me', target: '_blank' class: 'btn btn-secondary', rel: 'me', target: '_blank'
%li.nav-item %li.nav-item
= link_to t('.logout'), main_app.destroy_usuarie_session_path, = link_to t('.logout'), main_app.destroy_usuarie_session_path,
method: :delete, role: 'button', class: 'btn' method: :delete, role: 'button', class: 'btn btn-secondary'
- else - else
- params.permit! - params.permit!
- I18n.available_locales.each do |locale| - I18n.available_locales.each do |locale|

View file

@ -1,2 +1,2 @@
= link_to text, link, class: 'btn', = link_to text, link, class: 'btn btn-secondary',
data: { toggle: 'tooltip' }, 'aria-role': 'button', title: tooltip data: { toggle: 'tooltip' }, 'aria-role': 'button', title: tooltip

View file

@ -1,7 +1,7 @@
- invalid_help = site.config.fetch('invalid_help', t('.invalid_help')) - invalid_help = site.config.fetch('invalid_help', t('.invalid_help'))
- sending_help = site.config.fetch('sending_help', t('.sending_help')) - sending_help = site.config.fetch('sending_help', t('.sending_help'))
.form-group .form-group
= submit_tag t('.save'), class: 'btn submit-post' = submit_tag t('.save'), class: 'btn btn-secondary submit-post'
= render 'bootstrap/alert', class: 'invalid-help d-none' do = render 'bootstrap/alert', class: 'invalid-help d-none' do
= invalid_help = invalid_help
= render 'bootstrap/alert', class: 'sending-help d-none' do = render 'bootstrap/alert', class: 'sending-help d-none' do

View file

@ -20,82 +20,82 @@
TODO: Eliminar todo el espacio en blanco para minificar HTML TODO: Eliminar todo el espacio en blanco para minificar HTML
.editor-toolbar{ style: 'z-index: 1' } .editor-toolbar{ style: 'z-index: 1' }
.editor-primary-toolbar.scrollbar-black .editor-primary-toolbar.scrollbar-black
%button.btn{ type: 'button', title: t('editor.multimedia'), data: { editor_button: 'multimedia' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.multimedia'), data: { editor_button: 'multimedia' } }>
%i.fa.fa-fw.fa-upload> %i.fa.fa-fw.fa-upload>
%span.sr-only>= t('editor.multimedia') %span.sr-only>= t('editor.multimedia')
%button.btn{ type: 'button', title: t('editor.bold'), data: { editor_button: 'mark-bold' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.bold'), data: { editor_button: 'mark-bold' } }>
%i.fa.fa-fw.fa-bold> %i.fa.fa-fw.fa-bold>
%span.sr-only>= t('editor.bold') %span.sr-only>= t('editor.bold')
%button.btn{ type: 'button', title: t('editor.italic'), data: { editor_button: 'mark-italic' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.italic'), data: { editor_button: 'mark-italic' } }>
%i.fa.fa-fw.fa-italic> %i.fa.fa-fw.fa-italic>
%span.sr-only>= t('editor.italic') %span.sr-only>= t('editor.italic')
%button.btn{ type: 'button', title: t('editor.mark'), data: { editor_button: 'mark-mark' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.mark'), data: { editor_button: 'mark-mark' } }>
%i.fa.fa-fw.fa-tint> %i.fa.fa-fw.fa-tint>
%span.sr-only>= t('editor.mark') %span.sr-only>= t('editor.mark')
%button.btn{ type: 'button', title: t('editor.link'), data: { editor_button: 'mark-link' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.link'), data: { editor_button: 'mark-link' } }>
%i.fa.fa-fw.fa-link> %i.fa.fa-fw.fa-link>
%span.sr-only>= t('editor.link') %span.sr-only>= t('editor.link')
%button.btn{ type: 'button', title: t('editor.deleted'), data: { editor_button: 'mark-deleted' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.deleted'), data: { editor_button: 'mark-deleted' } }>
%i.fa.fa-fw.fa-strikethrough> %i.fa.fa-fw.fa-strikethrough>
%span.sr-only>= t('editor.deleted') %span.sr-only>= t('editor.deleted')
%button.btn{ type: 'button', title: t('editor.underline'), data: { editor_button: 'mark-underline' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.underline'), data: { editor_button: 'mark-underline' } }>
%i.fa.fa-fw.fa-underline> %i.fa.fa-fw.fa-underline>
%span.sr-only>= t('editor.underline') %span.sr-only>= t('editor.underline')
%button.btn{ type: 'button', title: t('editor.super'), data: { editor_button: 'mark-super' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.super'), data: { editor_button: 'mark-super' } }>
%i.fa.fa-fw.fa-superscript> %i.fa.fa-fw.fa-superscript>
%span.sr-only>= t('editor.super') %span.sr-only>= t('editor.super')
%button.btn{ type: 'button', title: t('editor.sub'), data: { editor_button: 'mark-sub' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.sub'), data: { editor_button: 'mark-sub' } }>
%i.fa.fa-fw.fa-subscript> %i.fa.fa-fw.fa-subscript>
%span.sr-only>= t('editor.sub') %span.sr-only>= t('editor.sub')
%button.btn{ type: 'button', title: t('editor.small'), data: { editor_button: 'mark-small' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.small'), data: { editor_button: 'mark-small' } }>
%i.fa.fa-fw.fa-subscript> %i.fa.fa-fw.fa-subscript>
%span.sr-only>= t('editor.small') %span.sr-only>= t('editor.small')
%button.btn.mr-0{ type: 'button', title: t('editor.h1'), data: { editor_button: 'block-h1' } }> %button.btn.btn-secondary.mr-0{ type: 'button', title: t('editor.h1'), data: { editor_button: 'block-h1' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
1 1
%span.sr-only>= t('editor.h1') %span.sr-only>= t('editor.h1')
%details.d-inline> %details.d-inline>
%summary.d-inline> %summary.d-inline>
%span.btn.ml-0{ role: 'button', title: t('editor.more') }> %span.btn.btn-secondary.ml-0{ role: 'button', title: t('editor.more') }>
%i.fa.fa-caret-right> %i.fa.fa-caret-right>
%span.sr-only= t('editor.more') %span.sr-only= t('editor.more')
.d-inline> .d-inline>
%button.btn{ type: 'button', title: t('editor.h2'), data: { editor_button: 'block-h2' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.h2'), data: { editor_button: 'block-h2' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
2 2
%span.sr-only>= t('editor.h2') %span.sr-only>= t('editor.h2')
%button.btn{ type: 'button', title: t('editor.h3'), data: { editor_button: 'block-h3' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.h3'), data: { editor_button: 'block-h3' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
3 3
%span.sr-only>= t('editor.h3') %span.sr-only>= t('editor.h3')
%button.btn{ type: 'button', title: t('editor.h4'), data: { editor_button: 'block-h4' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.h4'), data: { editor_button: 'block-h4' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
4 4
%span.sr-only>= t('editor.h4') %span.sr-only>= t('editor.h4')
%button.btn{ type: 'button', title: t('editor.h5'), data: { editor_button: 'block-h5' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.h5'), data: { editor_button: 'block-h5' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
5 5
%span.sr-only>= t('editor.h5') %span.sr-only>= t('editor.h5')
%button.btn{ type: 'button', title: t('editor.h6'), data: { editor_button: 'block-h6' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.h6'), data: { editor_button: 'block-h6' } }>
%i.fa.fa-fw.fa-heading> %i.fa.fa-fw.fa-heading>
6 6
%span.sr-only>= t('editor.h6') %span.sr-only>= t('editor.h6')
%button.btn{ type: 'button', title: t('editor.ul'), data: { editor_button: 'block-unordered_list' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.ul'), data: { editor_button: 'block-unordered_list' } }>
%i.fa.fa-fw.fa-list-ul> %i.fa.fa-fw.fa-list-ul>
%span.sr-only>= t('editor.ul') %span.sr-only>= t('editor.ul')
%button.btn{ type: 'button', title: t('editor.ol'), data: { editor_button: 'block-ordered_list' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.ol'), data: { editor_button: 'block-ordered_list' } }>
%i.fa.fa-fw.fa-list-ol> %i.fa.fa-fw.fa-list-ol>
%span.sr-only>= t('editor.ol') %span.sr-only>= t('editor.ol')
%button.btn{ type: 'button', title: t('editor.left'), data: { editor_button: 'parentBlock-left' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.left'), data: { editor_button: 'parentBlock-left' } }>
%i.fa.fa-fw.fa-align-left> %i.fa.fa-fw.fa-align-left>
%span.sr-only>= t('editor.left') %span.sr-only>= t('editor.left')
%button.btn{ type: 'button', title: t('editor.center'), data: { editor_button: 'parentBlock-center' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.center'), data: { editor_button: 'parentBlock-center' } }>
%i.fa.fa-fw.fa-align-center> %i.fa.fa-fw.fa-align-center>
%span.sr-only>= t('editor.center') %span.sr-only>= t('editor.center')
%button.btn{ type: 'button', title: t('editor.right'), data: { editor_button: 'parentBlock-right' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.right'), data: { editor_button: 'parentBlock-right' } }>
%i.fa.fa-fw.fa-align-right> %i.fa.fa-fw.fa-align-right>
%span.sr-only>= t('editor.right') %span.sr-only>= t('editor.right')
%button.btn{ type: 'button', title: t('editor.blockquote'), data: { editor_button: 'block-blockquote' } }> %button.btn.btn-secondary{ type: 'button', title: t('editor.blockquote'), data: { editor_button: 'block-blockquote' } }>
%i.fa.fa-fw.fa-quote-left> %i.fa.fa-fw.fa-quote-left>
%span.sr-only>= t('editor.blockquote') %span.sr-only>= t('editor.blockquote')
@ -116,8 +116,8 @@
%label{ for: 'multimedia-alt' }= t('editor.description') %label{ for: 'multimedia-alt' }= t('editor.description')
%input.form-control{ type: 'text', id: 'multimedia-alt', name: 'multimedia-alt' }/ %input.form-control{ type: 'text', id: 'multimedia-alt', name: 'multimedia-alt' }/
.form-group .form-group
%button.btn{ type: 'button', id: 'multimedia-file-upload', name: 'multimedia-file-upload' }= t('editor.multimedia-upload') %button.btn.btn-secondary{ type: 'button', id: 'multimedia-file-upload', name: 'multimedia-file-upload' }= t('editor.multimedia-upload')
%button.btn{ type: 'button', id: 'multimedia-remove', name: 'multimedia-remove' }= t('editor.multimedia-remove') %button.btn.btn-secondary{ type: 'button', id: 'multimedia-remove', name: 'multimedia-remove' }= t('editor.multimedia-remove')
.form-group{ data: { editor_auxiliary: 'link' } } .form-group{ data: { editor_auxiliary: 'link' } }
%label{ for: 'link-url' }= t('editor.url') %label{ for: 'link-url' }= t('editor.url')

View file

@ -1,3 +1,6 @@
.row.justify-content-center .row.justify-content-center
.col-md-8 .col-md-8
= render 'layouts/details', summary: "Post" do
= render 'posts/form', site: @site, post: @post = render 'posts/form', site: @site, post: @post
= render 'layouts/details', summary: t('.moderation_queue') do
= render 'posts/moderation_queue', site: @site, post: @post, moderation_queue: @moderation_queue

View file

@ -15,13 +15,13 @@
= render 'schemas/row', site: @site, schema: schema, filter: @filter_params = render 'schemas/row', site: @site, schema: schema, filter: @filter_params
- if policy(@site_stat).index? - if policy(@site_stat).index?
= link_to t('stats.index.title'), site_stats_path(@site), class: 'btn' = link_to t('stats.index.title'), site_stats_path(@site), class: 'btn btn-secondary'
- if policy(@site).edit? - if policy(@site).edit?
= link_to t('sites.edit.btn', site: @site.title), edit_site_path(@site), class: 'btn' = link_to t('sites.edit.btn', site: @site.title), edit_site_path(@site), class: 'btn btn-secondary'
- if policy(@site).private? - if policy(@site).private?
= link_to t('sites.private'), '../private/' + @site.name, class: 'btn', target: '_blank', rel: 'noopener' = link_to t('sites.private'), '../private/' + @site.name, class: 'btn btn-secondary', target: '_blank', rel: 'noopener'
- if policy(SiteUsuarie.new(@site, current_usuarie)).index? - if policy(SiteUsuarie.new(@site, current_usuarie)).index?
= render 'layouts/btn_with_tooltip', = render 'layouts/btn_with_tooltip',
@ -33,9 +33,9 @@
- if @site.design.credits - if @site.design.credits
= render 'bootstrap/alert' do = render 'bootstrap/alert' do
= sanitize_markdown @site.design.credits = sanitize_markdown @site.design.credits
= link_to t('sites.donations.text'), t('sites.donations.url'), class: 'btn' = link_to t('sites.donations.text'), t('sites.donations.url'), class: 'btn btn-secondary'
- if @site.design.designer_url - if @site.design.designer_url
= link_to t('sites.designer_url'), @site.design.designer_url, class: 'btn' = link_to t('sites.designer_url'), @site.design.designer_url, class: 'btn btn-secondary'
%section.col %section.col
.d-flex.justify-content-between.align-items-center.pl-2-plus.pr-2-plus.mb-2 .d-flex.justify-content-between.align-items-center.pl-2-plus.pr-2-plus.mb-2
@ -75,19 +75,19 @@
%th.border-0{ colspan: '4' } %th.border-0{ colspan: '4' }
.d-flex.flex-row.justify-content-between .d-flex.flex-row.justify-content-between
%div %div
= submit_tag t('posts.reorder.submit'), class: 'btn' = submit_tag t('posts.reorder.submit'), class: 'btn btn-secondary'
%button.btn{ data: { action: 'reorder#unselect' } } %button.btn.btn-secondary{ data: { action: 'reorder#unselect' } }
= t('posts.reorder.unselect') = t('posts.reorder.unselect')
%span.badge{ data: { target: 'reorder.counter' } } 0 %span.badge{ data: { target: 'reorder.counter' } } 0
%button.btn{ data: { action: 'reorder#up' } }= t('posts.reorder.up') %button.btn.btn-secondary{ data: { action: 'reorder#up' } }= t('posts.reorder.up')
%button.btn{ data: { action: 'reorder#down' } }= t('posts.reorder.down') %button.btn.btn-secondary{ data: { action: 'reorder#down' } }= t('posts.reorder.down')
%button.btn{ data: { action: 'reorder#top' } }= t('posts.reorder.top') %button.btn.btn-secondary{ data: { action: 'reorder#top' } }= t('posts.reorder.top')
%button.btn{ data: { action: 'reorder#bottom' } }= t('posts.reorder.bottom') %button.btn.btn-secondary{ data: { action: 'reorder#bottom' } }= t('posts.reorder.bottom')
- if @site.pagination - if @site.pagination
%div %div
= link_to_prev_page @posts, t('posts.prev'), class: 'btn' = link_to_prev_page @posts, t('posts.prev'), class: 'btn btn-secondary'
= link_to_next_page @posts, t('posts.next'), class: 'btn' = link_to_next_page @posts, t('posts.next'), class: 'btn btn-secondary'
%tbody %tbody
- dir = @site.data.dig(params[:locale], 'dir') - dir = @site.data.dig(params[:locale], 'dir')
- size = @posts.size - size = @posts.size
@ -126,9 +126,9 @@
= post.order = post.order
%td.text-nowrap %td.text-nowrap
- if @usuarie || policy(post).edit? - if @usuarie || policy(post).edit?
= link_to t('posts.edit'), edit_site_post_path(@site, post.path), class: 'btn btn-block' = link_to t('posts.edit'), edit_site_post_path(@site, post.path), class: 'btn btn-secondary btn-block'
- if @usuarie || policy(post).destroy? - if @usuarie || policy(post).destroy?
= link_to t('posts.destroy'), site_post_path(@site, post.path), class: 'btn btn-block', method: :delete, data: { confirm: t('posts.confirm_destroy') } = link_to t('posts.destroy'), site_post_path(@site, post.path), class: 'btn btn-secondary btn-block', method: :delete, data: { confirm: t('posts.confirm_destroy') }
#footnotes{ hidden: true } #footnotes{ hidden: true }
- @filter_params.each do |param, value| - @filter_params.each do |param, value|

View file

@ -4,7 +4,7 @@
%article.content.table-responsive-md %article.content.table-responsive-md
= link_to t('posts.edit'), = link_to t('posts.edit'),
edit_site_post_path(@site, @post.id), edit_site_post_path(@site, @post.id),
class: 'btn btn-block' class: 'btn btn-secondary btn-block'
%table.table.table-condensed %table.table.table-condensed
%thead %thead

View file

@ -3,7 +3,7 @@
method: :post, method: :post,
class: 'form-inline inline' do class: 'form-inline inline' do
= submit_tag site.enqueued? ? t('sites.enqueued') : t('sites.enqueue'), = submit_tag site.enqueued? ? t('sites.enqueued') : t('sites.enqueue'),
class: "btn no-border-radius #{local_assigns[:class]}", class: "btn btn-secondary #{local_assigns[:class]}",
title: site.enqueued? ? t('help.sites.enqueued') : t('help.sites.enqueue'), title: site.enqueued? ? t('help.sites.enqueued') : t('help.sites.enqueue'),
data: { disable_with: t('sites.enqueued') }, data: { disable_with: t('sites.enqueued') },
disabled: site.enqueued? disabled: site.enqueued?

View file

@ -72,10 +72,10 @@
.btn-group{ role: 'group', 'aria-label': t('.design.actions') } .btn-group{ role: 'group', 'aria-label': t('.design.actions') }
- if design.url - if design.url
= link_to t('.design.url'), design.url, = link_to t('.design.url'), design.url,
target: '_blank', class: 'btn' target: '_blank', class: 'btn btn-secondary'
- if design.license - if design.license
= link_to t('.design.license'), design.license, = link_to t('.design.license'), design.license,
target: '_blank', class: 'btn' target: '_blank', class: 'btn btn-secondary'
%hr/ %hr/
.form-group.licenses#license_id .form-group.licenses#license_id
@ -99,7 +99,7 @@
tags: %w[p a strong em ul ol li h1 h2 h3 h4 h5 h6] tags: %w[p a strong em ul ol li h1 h2 h3 h4 h5 h6]
- unless licencia.custom? - unless licencia.custom?
= link_to t('.licencia.url'), licencia.url, target: '_blank', class: 'btn', rel: 'noopener' = link_to t('.licencia.url'), licencia.url, target: '_blank', class: 'btn btn-secondary', rel: 'noopener'
%hr/ %hr/
@ -163,4 +163,4 @@
deploy: deploy, site: site deploy: deploy, site: site
.form-group .form-group
= f.submit submit, class: 'btn btn-lg btn-block' = f.submit submit, class: 'btn btn-secondary btn-lg btn-block'

View file

@ -27,4 +27,4 @@
.row.justify-content-center .row.justify-content-center
.col-md-8 .col-md-8
= link_to t('.merge.request'), site_pull_path(@site), = link_to t('.merge.request'), site_pull_path(@site),
method: 'post', class: 'btn btn-lg' method: 'post', class: 'btn btn-secondary btn-lg'

View file

@ -4,7 +4,7 @@
%p.lead= t('.help') %p.lead= t('.help')
- if policy(Site).new? - if policy(Site).new?
= link_to t('sites.new.title'), new_site_path, = link_to t('sites.new.title'), new_site_path,
class: 'btn' class: 'btn btn-secondary'
%section.col %section.col
- if @sites.empty? - if @sites.empty?
@ -29,18 +29,18 @@
= site.title = site.title
%p.lead= site.description %p.lead= site.description
%br %br
= link_to t('.visit'), site.url, class: 'btn' = link_to t('.visit'), site.url, class: 'btn btn-secondary'
- if rol.temporal - if rol.temporal
= button_to t('sites.invitations.accept'), = button_to t('sites.invitations.accept'),
site_usuaries_accept_invitation_path(site), site_usuaries_accept_invitation_path(site),
method: :patch, method: :patch,
title: t('help.sites.invitations.accept'), title: t('help.sites.invitations.accept'),
class: 'btn' class: 'btn btn-secondary'
= button_to t('sites.invitations.reject'), = button_to t('sites.invitations.reject'),
site_usuaries_reject_invitation_path(site), site_usuaries_reject_invitation_path(site),
method: :patch, method: :patch,
title: t('help.sites.invitations.reject'), title: t('help.sites.invitations.reject'),
class: 'btn' class: 'btn btn-secondary'
- else - else
- if policy(site).show? - if policy(site).show?
= render 'layouts/btn_with_tooltip', = render 'layouts/btn_with_tooltip',

View file

@ -11,11 +11,11 @@
%form.mb-5.form-inline{ method: 'get' } %form.mb-5.form-inline{ method: 'get' }
- Stat::INTERVALS.each do |interval| - Stat::INTERVALS.each do |interval|
= link_to t(".#{interval}"), site_stats_path(interval: interval, urls: params[:urls], period_start: params[:period_start].to_date.try(:"beginning_of_#{interval}").to_date, period_end: params[:period_end]), class: "mb-0 btn #{'btn-primary active' if @interval == interval}" = link_to t(".#{interval}"), site_stats_path(interval: interval, urls: params[:urls], period_start: params[:period_start].to_date.try(:"beginning_of_#{interval}").to_date, period_end: params[:period_end]), class: "mb-0 btn #{@interval == interval ? 'btn-primary active' : 'btn-secondary' }"
%input.form-control{ type: 'date', name: :period_start, value: params[:period_start] } %input.form-control{ type: 'date', name: :period_start, value: params[:period_start] }
%input.form-control{ type: 'date', name: :period_end, value: params[:period_end] } %input.form-control{ type: 'date', name: :period_end, value: params[:period_end] }
%button.btn.mb-0{ type: 'submit' }= t('.filter') %button.btn.btn-secondary.mb-0{ type: 'submit' }= t('.filter')
.mb-5 .mb-5
%h2= t('.host.title', count: @hostnames.size) %h2= t('.host.title', count: @hostnames.size)
@ -34,7 +34,7 @@
%textarea#urls.form-control{ name: 'urls', autocomplete: 'on', required: true, rows: @normalized_urls.size + 1, aria_describedby: 'help-urls' }= @normalized_urls.join("\n") %textarea#urls.form-control{ name: 'urls', autocomplete: 'on', required: true, rows: @normalized_urls.size + 1, aria_describedby: 'help-urls' }= @normalized_urls.join("\n")
%small#help-urls.feedback.form-text.text-muted= t('.urls.help') %small#help-urls.feedback.form-text.text-muted= t('.urls.help')
.form-group .form-group
%button.btn{ type: 'submit' }= t('.urls.submit') %button.btn.btn-secondary{ type: 'submit' }= t('.urls.submit')
- if @normalized_urls.present? - if @normalized_urls.present?
= line_chart site_stats_uris_path(urls: @normalized_urls, **@chart_params), **@chart_options = line_chart site_stats_uris_path(urls: @normalized_urls, **@chart_params), **@chart_options

View file

@ -9,13 +9,13 @@
- if @policy.invite? - if @policy.invite?
= link_to t('.invite'), = link_to t('.invite'),
site_usuaries_invite_path(@site, invite_as: u.to_s), site_usuaries_invite_path(@site, invite_as: u.to_s),
class: 'btn', class: 'btn btn-secondary',
data: { toggle: 'tooltip' }, data: { toggle: 'tooltip' },
title: t('.help.invite', invite_as: u.to_s) title: t('.help.invite', invite_as: u.to_s)
- if policy(Collaboration.new(@site)).collaborate? - if policy(Collaboration.new(@site)).collaborate?
= link_to t('.public_invite'), = link_to t('.public_invite'),
site_collaborate_path(@site), site_collaborate_path(@site),
class: 'btn', class: 'btn btn-secondary',
data: { toggle: 'tooltip' }, data: { toggle: 'tooltip' },
title: t('.help.public_invite') title: t('.help.public_invite')
%p.lead= t(".help.#{u}") %p.lead= t(".help.#{u}")
@ -38,7 +38,7 @@
- if @policy.demote? && @site.usuarie?(cuenta) - if @policy.demote? && @site.usuarie?(cuenta)
= link_to t('.demote.text'), = link_to t('.demote.text'),
site_usuarie_demote_path(@site, cuenta), site_usuarie_demote_path(@site, cuenta),
class: 'btn', class: 'btn btn-secondary',
data: { toggle: 'tooltip', data: { toggle: 'tooltip',
confirm: t('.demote.confirm') }, confirm: t('.demote.confirm') },
title: t('.help.demote'), title: t('.help.demote'),
@ -46,7 +46,7 @@
- if @policy.promote? && @site.invitade?(cuenta) - if @policy.promote? && @site.invitade?(cuenta)
= link_to t('.promote.text'), = link_to t('.promote.text'),
site_usuarie_promote_path(@site, cuenta), site_usuarie_promote_path(@site, cuenta),
class: 'btn', class: 'btn btn-secondary',
data: { toggle: 'tooltip', data: { toggle: 'tooltip',
confirm: t('.promote.confirm') }, confirm: t('.promote.confirm') },
title: t('.help.promote'), title: t('.help.promote'),
@ -54,7 +54,7 @@
- if @policy.destroy? - if @policy.destroy?
= link_to t('.destroy.text'), = link_to t('.destroy.text'),
site_usuarie_path(@site, cuenta), site_usuarie_path(@site, cuenta),
class: 'btn', class: 'btn btn-secondary',
data: { toggle: 'tooltip', data: { toggle: 'tooltip',
confirm: t('.destroy.confirm') }, confirm: t('.destroy.confirm') },
title: t('.help.destroy'), title: t('.help.destroy'),

View file

@ -13,4 +13,4 @@
invite_as: invite_as) invite_as: invite_as)
= f.text_area :invitaciones, class: 'form-control' = f.text_area :invitaciones, class: 'form-control'
.form-group .form-group
= f.submit t('.submit'), class: 'btn' = f.submit t('.submit'), class: 'btn btn-secondary'