1
0

app.css 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364
  1. .pywebio {
  2. min-height: 100vh;
  3. padding-top: 20px;
  4. padding-bottom: 1px; /* if set 0, safari has min-height issue */
  5. }
  6. .markdown-body hr {
  7. height: 2px;
  8. padding: 0;
  9. margin: 24px 0;
  10. background-color: #eaecef;
  11. border: 0;
  12. }
  13. .container {
  14. margin-top: 0;
  15. max-width: 880px;
  16. }
  17. #input-cards{
  18. max-width: 880px;
  19. }
  20. #output-container {
  21. -webkit-font-smoothing: antialiased;
  22. margin-bottom: 20px;
  23. }
  24. #input-container h5.card-header {
  25. padding: .4rem 1.25rem;
  26. }
  27. #input-container {
  28. z-index: 100;
  29. background: white;
  30. position: static;
  31. height: fit-content;
  32. box-shadow: none;
  33. margin-top: 0;
  34. margin-bottom: 40px; /* must equal #input-container.fixed padding-bottom */
  35. }
  36. #input-container.fixed {
  37. position: fixed !important;
  38. overflow: visible;
  39. bottom: 0;
  40. left: 0;
  41. right: 0;
  42. height: 0;
  43. box-shadow: 0 0 12px 1px rgba(80, 80, 80, 0.2);
  44. margin-bottom: 0;
  45. padding: 40px 0; /* must equal #input-container margin-bottom */
  46. }
  47. #input-container .card {
  48. margin: 0 auto;
  49. }
  50. .footer {
  51. height: 50px;
  52. text-align: center;
  53. color: gray;
  54. background-color: #efefef;
  55. line-height: 50px; /*设置line-height与父级元素的height相等, 以实现垂直居中*/
  56. margin: 0 auto;
  57. }
  58. .footer hr {
  59. margin-bottom: 0.5rem;
  60. }
  61. .footer a:visited {
  62. color: #9B59B6;
  63. }
  64. .footer a {
  65. color: #2980B9;
  66. text-decoration: none;
  67. cursor: pointer;
  68. }
  69. #title {
  70. text-align: center;
  71. position: absolute;
  72. left: 50%;
  73. transform: translateX(-50%);
  74. white-space: nowrap;
  75. }
  76. /* Amend markdown style */
  77. .markdown-body {
  78. font-family: inherit;
  79. color: inherit;
  80. }
  81. .markdown-body blockquote, .markdown-body dl, .markdown-body ol, .markdown-body p, .markdown-body pre, .markdown-body table, .markdown-body ul, .markdown-body details {
  82. margin-bottom: 10px;
  83. }
  84. .CodeMirror {
  85. font-size: 13px
  86. }
  87. h5.card-header:empty {
  88. padding: 0 !important;
  89. border-bottom: 0 !important;
  90. }
  91. button {
  92. margin-bottom: 8px;
  93. }
  94. td blockquote, td dl, td ol, td p, td pre, td table, td ul, td button, td pre {
  95. margin-bottom: 0 !important;
  96. }
  97. .input-container .form-group {
  98. margin-bottom: 0;
  99. }
  100. img {
  101. -webkit-animation-name: image-load-in;
  102. animation-name: image-load-in;
  103. -webkit-animation-duration: .6s;
  104. animation-duration: .6s
  105. }
  106. @-webkit-keyframes image-load-in {
  107. 0% {
  108. -webkit-filter: blur(8px);
  109. filter: blur(8px);
  110. opacity: 0
  111. }
  112. 100% {
  113. -webkit-filter: blur(0);
  114. filter: blur(0);
  115. opacity: 1
  116. }
  117. }
  118. @keyframes image-load-in {
  119. 0% {
  120. -webkit-filter: blur(8px);
  121. filter: blur(8px);
  122. opacity: 0
  123. }
  124. 100% {
  125. -webkit-filter: blur(0);
  126. filter: blur(0);
  127. opacity: 1
  128. }
  129. }
  130. .custom-file {
  131. margin-bottom: 8px;
  132. }
  133. summary:focus {
  134. outline: none;
  135. }
  136. details {
  137. border: 1px solid rgba(0,0,0,.125);
  138. border-radius: 4px;
  139. padding: .5em .5em 0;
  140. }
  141. summary {
  142. /*font-weight: bold;*/
  143. margin: -.5em -.5em 0;
  144. padding: .5em;
  145. background-color: rgba(0,0,0,.03);
  146. }
  147. details[open] {
  148. padding: .5em;
  149. }
  150. details[open]>summary {
  151. border-bottom: 1px solid rgba(0,0,0,.125);
  152. margin-bottom: .5em;
  153. }
  154. .actions-result {
  155. display: inline-block;
  156. font-weight: 400;
  157. color: #212529;
  158. text-align: center;
  159. vertical-align: middle;
  160. padding: .375rem .75rem;
  161. font-size: 1rem;
  162. line-height: 1.5;
  163. margin-bottom: 8px;
  164. }
  165. .hide{
  166. display: none;
  167. }
  168. .single-input-action-btn{
  169. border-top-right-radius: 0.25rem!important;
  170. border-bottom-right-radius: 0.25rem!important;
  171. }
  172. .alert-success > a {
  173. color: #0b2e13;
  174. }
  175. .alert-danger > a {
  176. color: #491217;
  177. }
  178. .alert-warning > a {
  179. color: #533f03;
  180. }
  181. .alert-info > a {
  182. color: #062c33;
  183. }
  184. .alert > a {
  185. font-weight: 700;
  186. }
  187. /*Tabs widget style*/
  188. /*Credit: https://themes.gohugo.io/theme/hugo-book/docs/shortcodes/tabs/ Licensed by MIT */
  189. .webio-tabs {
  190. margin-top: 1rem;
  191. margin-bottom: 1rem;
  192. border: 1px solid #e9ecef;
  193. border-radius: .25rem;
  194. display: flex;
  195. flex-wrap: wrap;
  196. align-content: flex-start;
  197. }
  198. .webio-tabs > label {
  199. display: inline-block;
  200. padding: .5rem 1rem;
  201. border-bottom: 1px transparent;
  202. cursor: pointer;
  203. margin-bottom: 0!important;
  204. }
  205. .webio-tabs > label:hover {
  206. background-color: #e9ecef;
  207. }
  208. .webio-tabs > .webio-tabs-content {
  209. order: 999;
  210. width: 100%;
  211. border-top: 1px solid #f5f5f5;
  212. padding: 1rem;
  213. display: none
  214. }
  215. .webio-tabs > input[type=radio]:checked + label {
  216. border-bottom: 2px solid #0055bb
  217. }
  218. .webio-tabs > input[type=radio]:checked + label + .webio-tabs-content {
  219. display: block
  220. }
  221. .webio-tabs > input.toggle {
  222. height: 0;
  223. width: 0;
  224. overflow: hidden;
  225. opacity: 0;
  226. position: absolute;
  227. }
  228. .webio-tabs > [type=radio] {
  229. box-sizing: border-box;
  230. padding: 0;
  231. }
  232. /*End of Tabs widget*/
  233. .custom-file-label > span {
  234. overflow: hidden;
  235. width: calc(100% - 6ch - 0.75rem) !important; /* 6ch is for "Browse", 0.75rem is for the padding of "Browse" button */
  236. text-overflow: ellipsis;
  237. white-space: nowrap;
  238. display: inline-block !important;
  239. }
  240. .CodeMirror-fullscreen {
  241. position: fixed;
  242. top: 0; left: 0; right: 0; bottom: 0;
  243. height: auto;
  244. z-index: 9;
  245. }
  246. .pywebio-clickable{
  247. cursor: pointer;
  248. }
  249. /* scrollable widget */
  250. .webio-scrollable{
  251. overflow: auto;
  252. margin-bottom: 10px;
  253. }
  254. .webio-scrollable.scrollable-border{
  255. padding: 10px;
  256. border: 1px solid rgba(0,0,0,.125);
  257. box-shadow: inset 0 0 2px 0 rgba(0,0,0,.1);
  258. }
  259. /* dark theme */
  260. .webio-theme-dark #input-container {
  261. background: #0d1117;
  262. }
  263. .webio-theme-dark #input-container.fixed {
  264. box-shadow: 0px 0px 8px 5px rgb(0 0 0);
  265. }
  266. .webio-theme-dark .footer {
  267. background-color: #0d1117;
  268. border-top: 1px solid #30363d;
  269. }
  270. .webio-theme-dark .webio-tabs {
  271. border: 1px solid #343a40;
  272. }
  273. .webio-theme-dark .webio-tabs > .webio-tabs-content {
  274. border-top: 1px solid #343a40;
  275. }
  276. .webio-theme-dark .webio-tabs > label:hover {
  277. background-color: #000;
  278. }
  279. .webio-theme-dark .webio-tabs > input[type=radio]:checked + label {
  280. border-bottom: 2px solid #0040a1;
  281. }
  282. .webio-theme-dark .scrollable-border{
  283. border: 1px solid #343a40;
  284. }
  285. .webio-theme-dark details{
  286. border: 1px solid #343a40;
  287. }
  288. .webio-theme-dark details>summary{
  289. background-color: #191d21;
  290. }
  291. .webio-theme-dark details[open]>summary{
  292. border-bottom: 1px solid #343a40;
  293. }
  294. /* dark theme end */
  295. /* For range input */
  296. .form-control-range {
  297. display:inline;
  298. width:calc(100% - 40px);
  299. }
  300. .form-control-range-value{
  301. display: inline-block;
  302. max-width: 35px;
  303. white-space: nowrap;
  304. color: #6c757d;
  305. line-height: 14px;
  306. vertical-align: text-top;
  307. }