You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

242 line
4.3 KiB

  1. /* checkbox */
  2. .checkbox {
  3. label {
  4. display: inline-flex;
  5. align-items: center;
  6. margin-bottom: 0;
  7. }
  8. --checkbox-right-margin: 8px;
  9. .label-area {
  10. font-size: var(--text-sm);
  11. }
  12. .input-area, .disp-area {
  13. display: flex;
  14. }
  15. }
  16. $check-icon: url("data:image/svg+xml, <svg viewBox='0 0 8 7' fill='none' xmlns='http://www.w3.org/2000/svg'><path d='M1 4.00001L2.66667 5.80001L7 1.20001' stroke='white' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  17. input[type="radio"] {
  18. position: relative;
  19. width: var(--checkbox-size) !important;
  20. height: var(--checkbox-size);
  21. margin-right: 8px !important;
  22. font-size: calc(var(--checkbox-size) - 1px);
  23. background-repeat: no-repeat;
  24. background-position: center;
  25. cursor: pointer;
  26. // Reset browser behavior
  27. -webkit-appearance: none;
  28. -moz-appearance: none;
  29. appearance: none;
  30. -webkit-print-color-adjust: exact;
  31. color-adjust: exact;
  32. &:focus {
  33. outline: none;
  34. }
  35. &:before {
  36. width: var(--checkbox-size);
  37. height: var(--checkbox-size);
  38. position: absolute;
  39. content: ' ';
  40. border: 1px solid var(--gray-400);
  41. border-radius: 16px;
  42. }
  43. &:checked::before {
  44. background-color: #2490EF;
  45. border-radius: 16px;
  46. box-shadow: inset 0 0 0 2px white;
  47. }
  48. }
  49. input[type="checkbox"] {
  50. position: relative;
  51. width: var(--checkbox-size) !important;
  52. height: var(--checkbox-size);
  53. margin-right: var(--checkbox-right-margin) !important;
  54. background-repeat: no-repeat;
  55. background-position: center;
  56. border: 1px solid var(--gray-400);
  57. box-sizing: border-box;
  58. box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.1);
  59. border-radius: 4px;
  60. // Reset browser behavior
  61. -webkit-appearance: none;
  62. -moz-appearance: none;
  63. appearance: none;
  64. -webkit-print-color-adjust: exact;
  65. color-adjust: exact;
  66. .grid-static-col & {
  67. margin-right: 0 !important;
  68. }
  69. &:checked {
  70. background-color: #2490EF;
  71. background-image: $check-icon, linear-gradient(180deg, #4AC3F8 -124.51%, #2490EF 100%);
  72. background-size: 57%, 100%;
  73. box-shadow: none;
  74. border: none;
  75. }
  76. &:focus {
  77. outline: none; // Prevent browser behavior
  78. box-shadow: var(--checkbox-focus-shadow);
  79. }
  80. &.disabled-deselected, &:disabled {
  81. background-color: var(--disabled-control-bg);
  82. box-shadow: inset 0px 1px 7px rgba(0, 0, 0, 0.1);
  83. border: 0.5px solid var(--gray-300);
  84. pointer-events: none;
  85. }
  86. &.disabled-selected, &:disabled:checked {
  87. background-color: var(--gray-500);
  88. background-image: $check-icon;
  89. background-size: 57%;
  90. box-shadow: inset 0px 1px 3px rgba(0, 0, 0, 0.1);
  91. border: none;
  92. pointer-events: none;
  93. }
  94. }
  95. .frappe-card {
  96. @include card();
  97. }
  98. .frappe-control[data-fieldtype="Select"].frappe-control[data-fieldname="color"] {
  99. select {
  100. padding-left: 40px;
  101. }
  102. .color-box {
  103. position: absolute;
  104. top: calc(50% - 11px);
  105. left: 8px;
  106. width: 22px;
  107. height: 22px;
  108. border-radius: 5px;
  109. z-index: 1;
  110. }
  111. }
  112. .frappe-control[data-fieldtype="Select"] .control-input,
  113. .frappe-control[data-fieldtype="Select"].form-group {
  114. position: relative;
  115. select {
  116. /* for Firefox */
  117. -moz-appearance: none;
  118. /* for Chrome */
  119. -webkit-appearance: none;
  120. }
  121. .select-icon {
  122. padding-left: inherit;
  123. padding-right: inherit;
  124. position: absolute;
  125. pointer-events: none;
  126. top: 7px;
  127. right: 12px;
  128. &.xs {
  129. top: 3px;
  130. right: 10px;
  131. }
  132. .icon {
  133. use {
  134. stroke: var(--text-muted);
  135. }
  136. }
  137. }
  138. .placeholder {
  139. padding-left: inherit;
  140. padding-right: inherit;
  141. position: absolute;
  142. pointer-events: none;
  143. top: 7px;
  144. left: 12px;
  145. max-width: 80%;
  146. &.xs {
  147. top: 3px;
  148. }
  149. }
  150. }
  151. .no-border {
  152. border: none !important;
  153. }
  154. .whitespace-nowrap {
  155. white-space: nowrap;
  156. }
  157. .app-change-log-body {
  158. h1 {
  159. font-size: var(--text-2xl);
  160. }
  161. }
  162. .new-version-log {
  163. .new-version-links {
  164. padding: var(--padding-xs) 0px;
  165. }
  166. &:not(:last-child) {
  167. margin-bottom: 1em;
  168. }
  169. }
  170. .centered {
  171. position: absolute;
  172. top: 50%;
  173. left: 50%;
  174. transform: translate(-50%, -50%);
  175. -webkit-transform: translate(-50%, -50%);
  176. }
  177. .hide {
  178. display: none !important;
  179. }
  180. .btn-link {
  181. box-shadow: none !important;
  182. outline: none;
  183. .icon, &:hover {
  184. text-decoration: none !important;
  185. }
  186. }
  187. .hidden {
  188. @extend .d-none;
  189. }
  190. .margin {
  191. margin: var(--margin-sm);
  192. }
  193. .margin-top {
  194. margin-top: var(--margin-sm);
  195. }
  196. .margin-bottom {
  197. margin-bottom: var(--margin-sm);
  198. }
  199. .margin-left {
  200. margin-left: var(--margin-sm);
  201. }
  202. .margin-right {
  203. margin-right: var(--margin-sm);
  204. }