From 408e54affe97369fbee0fb9f279bc21f189c6a92 Mon Sep 17 00:00:00 2001 From: Bohung Date: Mon, 28 Jun 2021 18:35:12 +0800 Subject: [PATCH] Update. Fix accessibility. --- assets/stylesheets/bootstrap/_variables.scss | 50 +++++++++---------- .../stylesheets/template/modules/epaper.scss | 4 +- assets/stylesheets/template/template.scss | 2 +- modules/member/member_index2.html.erb | 2 +- modules/member/member_index3.html.erb | 2 +- modules/member/member_index4.html.erb | 2 +- modules/member/member_index5.html.erb | 2 +- 7 files changed, 32 insertions(+), 32 deletions(-) diff --git a/assets/stylesheets/bootstrap/_variables.scss b/assets/stylesheets/bootstrap/_variables.scss index 83a9527..b45580c 100644 --- a/assets/stylesheets/bootstrap/_variables.scss +++ b/assets/stylesheets/bootstrap/_variables.scss @@ -49,21 +49,21 @@ $font-family-serif: Georgia, "Times New Roman", Times, serif !default; $font-family-monospace: Menlo, Monaco, Consolas, "Courier New", monospace !default; $font-family-base: $font-family-sans-serif !default; -$font-size-base: 14px !default; +$font-size-base: 0.875em !default; $font-size-large: ceil(($font-size-base * 1.25)) !default; // ~18px -$font-size-small: ceil(($font-size-base * 0.85)) !default; // ~12px +$font-size-small: ceil(($font-size-base * 0.85)) !default; // ~0.75em $font-size-h1: floor(($font-size-base * 2.6)) !default; // ~36px $font-size-h2: floor(($font-size-base * 2.15)) !default; // ~30px $font-size-h3: ceil(($font-size-base * 1.7)) !default; // ~24px $font-size-h4: ceil(($font-size-base * 1.25)) !default; // ~18px $font-size-h5: $font-size-base !default; -$font-size-h6: ceil(($font-size-base * 0.85)) !default; // ~12px +$font-size-h6: ceil(($font-size-base * 0.85)) !default; // ~0.75em //** Unit-less `line-height` for use in components like buttons. $line-height-base: 1.428571429 !default; // 20/14 //** Computed "line-height" (`font-size` * `line-height`) for use with `margin`, `padding`, etc. -$line-height-computed: floor(($font-size-base * $line-height-base)) !default; // ~20px +$line-height-computed: floor(($font-size-base * $line-height-base)) !default; // ~1.25em //** By default, this inherits from the ``. $headings-font-family: inherit !default; @@ -82,25 +82,25 @@ $icon-font-svg-id: "glyphicons_halflingsregular" !default; //== Components // -//## Define common padding and border radius sizes and more. Values based on 14px text and 1.428 line-height (~20px to start). +//## Define common padding and border radius sizes and more. Values based on 14px text and 1.428 line-height (~1.25em to start). -$padding-base-vertical: 6px !default; -$padding-base-horizontal: 12px !default; +$padding-base-vertical: 0.375em !default; +$padding-base-horizontal: 0.75em !default; -$padding-large-vertical: 10px !default; -$padding-large-horizontal: 16px !default; +$padding-large-vertical: 0.625em !default; +$padding-large-horizontal: 1em !default; -$padding-small-vertical: 5px !default; -$padding-small-horizontal: 10px !default; +$padding-small-vertical: 0.3125em !default; +$padding-small-horizontal: 0.625em !default; -$padding-xs-vertical: 1px !default; -$padding-xs-horizontal: 5px !default; +$padding-xs-vertical: 0.0625em !default; +$padding-xs-horizontal: 0.3125em !default; $line-height-large: 1.33 !default; $line-height-small: 1.5 !default; $border-radius-base: 4px !default; -$border-radius-large: 6px !default; +$border-radius-large: 0.375em !default; $border-radius-small: 3px !default; //** Global color for active items (e.g., navs or dropdowns). @@ -111,7 +111,7 @@ $component-active-bg: $brand-primary !default; //** Width of the `border` for generating carets that indicator dropdowns. $caret-width-base: 4px !default; //** Carets increase slightly in size for larger components. -$caret-width-large: 5px !default; +$caret-width-large: 0.3125em !default; //== Tables @@ -121,7 +121,7 @@ $caret-width-large: 5px !default; //** Padding for ``s and ``s. $table-cell-padding: 8px !default; //** Padding for cells in `.table-condensed`. -$table-condensed-cell-padding: 5px !default; +$table-condensed-cell-padding: 0.3125em !default; //** Default background color used for all tables. $table-bg: transparent !default; @@ -330,7 +330,7 @@ $container-lg: $container-large-desktop !default; //## // Basics of a navbar -$navbar-height: 50px !default; +$navbar-height: 3.125em !default; $navbar-margin-bottom: $line-height-computed !default; $navbar-border-radius: $border-radius-base !default; $navbar-padding-horizontal: floor(($grid-gutter-width / 2)) !default; @@ -392,7 +392,7 @@ $navbar-inverse-toggle-border-color: #333 !default; //## //=== Shared nav styles -$nav-link-padding: 10px 15px !default; +$nav-link-padding: 0.625em 15px !default; $nav-link-hover-bg: $gray-lighter !default; $nav-disabled-link-color: $gray-light !default; @@ -500,7 +500,7 @@ $tooltip-bg: #000 !default; $tooltip-opacity: .9 !default; //** Tooltip arrow width -$tooltip-arrow-width: 5px !default; +$tooltip-arrow-width: 0.3125em !default; //** Tooltip arrow color $tooltip-arrow-color: $tooltip-bg !default; @@ -522,7 +522,7 @@ $popover-fallback-border-color: #ccc !default; $popover-title-bg: darken($popover-bg, 3%) !default; //** Popover arrow width -$popover-arrow-width: 10px !default; +$popover-arrow-width: 0.625em !default; //** Popover arrow color $popover-arrow-color: #fff !default; @@ -562,7 +562,7 @@ $label-link-hover-color: #fff !default; //## //** Padding applied to the modal body -$modal-inner-padding: 20px !default; +$modal-inner-padding: 1.25em !default; //** Padding applied to the modal title $modal-title-padding: 15px !default; @@ -741,7 +741,7 @@ $badge-active-bg: #fff !default; $badge-font-weight: bold !default; $badge-line-height: 1 !default; -$badge-border-radius: 10px !default; +$badge-border-radius: 0.625em !default; //== Breadcrumbs @@ -764,12 +764,12 @@ $breadcrumb-separator: "/" !default; // //## -$carousel-text-shadow: 0 1px 2px rgba(0,0,0,.6) !default; +$carousel-text-shadow: 0 0.0625em 0.125em rgba(0,0,0,.6) !default; $carousel-control-color: #fff !default; $carousel-control-width: 15% !default; $carousel-control-opacity: .5 !default; -$carousel-control-font-size: 20px !default; +$carousel-control-font-size: 1.25em !default; $carousel-indicator-active-bg: #fff !default; $carousel-indicator-border-color: #fff !default; @@ -783,7 +783,7 @@ $carousel-caption-color: #fff !default; $close-font-weight: bold !default; $close-color: #000 !default; -$close-text-shadow: 0 1px 0 #fff !default; +$close-text-shadow: 0 0.0625em 0 #fff !default; //== Code diff --git a/assets/stylesheets/template/modules/epaper.scss b/assets/stylesheets/template/modules/epaper.scss index d903467..e048089 100644 --- a/assets/stylesheets/template/modules/epaper.scss +++ b/assets/stylesheets/template/modules/epaper.scss @@ -19,7 +19,7 @@ border-left: 6px solid rgb(105, 150, 171); background: rgb(74, 42, 36); color: rgb(255, 255, 255); - font-size: 14px; + font-size: 0.875em; font-family: 微軟正黑體; } tbody { @@ -178,7 +178,7 @@ border: 1px solid #d1d1d1; background: #f0f0f0; padding: 4px 6px; - font-size: 14px; + font-size: 0.875em; margin-top:-3px; } } diff --git a/assets/stylesheets/template/template.scss b/assets/stylesheets/template/template.scss index 867f4f3..da39b7c 100644 --- a/assets/stylesheets/template/template.scss +++ b/assets/stylesheets/template/template.scss @@ -73,7 +73,7 @@ padding: 5px 10px; background: $theme-color-main; color:#fff; - font-size: 18px; + font-size: 1.125em; transition:.3s; &:hover{ background: $theme-color-second; diff --git a/modules/member/member_index2.html.erb b/modules/member/member_index2.html.erb index 7d4f475..ec2f6c6 100644 --- a/modules/member/member_index2.html.erb +++ b/modules/member/member_index2.html.erb @@ -14,7 +14,7 @@
diff --git a/modules/member/member_index3.html.erb b/modules/member/member_index3.html.erb index 5964980..c3aa1da 100644 --- a/modules/member/member_index3.html.erb +++ b/modules/member/member_index3.html.erb @@ -14,7 +14,7 @@
  • - {{title}}: + {{title}} : {{value}}
diff --git a/modules/member/member_index4.html.erb b/modules/member/member_index4.html.erb index 2173460..25a580a 100644 --- a/modules/member/member_index4.html.erb +++ b/modules/member/member_index4.html.erb @@ -9,7 +9,7 @@
  • - {{title}} + {{title}} : {{value}}
diff --git a/modules/member/member_index5.html.erb b/modules/member/member_index5.html.erb index 09f8059..8b3a0f4 100644 --- a/modules/member/member_index5.html.erb +++ b/modules/member/member_index5.html.erb @@ -14,7 +14,7 @@
  • - {{title}} + {{title}} : {{value}}