app.css 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453
  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, .form-group button, td pre {
  95. margin-bottom: 0 !important;
  96. }
  97. .form-group {
  98. margin-bottom: 0.4rem;
  99. }
  100. .form-group label {
  101. margin-bottom: 0px;
  102. }
  103. #input-container .card-body {
  104. padding: 0.8rem 1.25rem;
  105. }
  106. img {
  107. -webkit-animation-name: image-load-in;
  108. animation-name: image-load-in;
  109. -webkit-animation-duration: .6s;
  110. animation-duration: .6s
  111. }
  112. .no-animation img {
  113. -webkit-animation-name: none;
  114. animation-name: none
  115. }
  116. @-webkit-keyframes image-load-in {
  117. 0% {
  118. -webkit-filter: blur(8px);
  119. filter: blur(8px);
  120. opacity: 0
  121. }
  122. 100% {
  123. -webkit-filter: blur(0);
  124. filter: blur(0);
  125. opacity: 1
  126. }
  127. }
  128. @keyframes image-load-in {
  129. 0% {
  130. -webkit-filter: blur(8px);
  131. filter: blur(8px);
  132. opacity: 0
  133. }
  134. 100% {
  135. -webkit-filter: blur(0);
  136. filter: blur(0);
  137. opacity: 1
  138. }
  139. }
  140. .custom-file {
  141. margin-bottom: 8px;
  142. }
  143. summary:focus {
  144. outline: none;
  145. }
  146. details {
  147. border: 1px solid rgba(0,0,0,.125);
  148. border-radius: 4px;
  149. padding: .5em .5em 0;
  150. }
  151. summary {
  152. /*font-weight: bold;*/
  153. margin: -.5em -.5em 0;
  154. padding: .5em;
  155. background-color: rgba(0,0,0,.03);
  156. }
  157. details[open] {
  158. padding: .5em;
  159. }
  160. details[open]>summary {
  161. border-bottom: 1px solid rgba(0,0,0,.125);
  162. margin-bottom: .5em;
  163. }
  164. .actions-result {
  165. display: inline-block;
  166. font-weight: 400;
  167. color: #212529;
  168. text-align: center;
  169. vertical-align: middle;
  170. padding: .375rem .75rem;
  171. font-size: 1rem;
  172. line-height: 1.5;
  173. margin-bottom: 8px;
  174. }
  175. .hide{
  176. display: none;
  177. }
  178. .single-input-action-btn{
  179. border-top-right-radius: 0.25rem!important;
  180. border-bottom-right-radius: 0.25rem!important;
  181. }
  182. .alert-success > a {
  183. color: #0b2e13;
  184. }
  185. .alert-danger > a {
  186. color: #491217;
  187. }
  188. .alert-warning > a {
  189. color: #533f03;
  190. }
  191. .alert-info > a {
  192. color: #062c33;
  193. }
  194. .alert > a {
  195. font-weight: 700;
  196. }
  197. /*Tabs widget style*/
  198. /*Credit: https://themes.gohugo.io/theme/hugo-book/docs/shortcodes/tabs/ Licensed by MIT */
  199. .webio-tabs {
  200. margin-top: 1rem;
  201. margin-bottom: 1rem;
  202. border: 1px solid #e9ecef;
  203. border-radius: .25rem;
  204. display: flex;
  205. flex-wrap: wrap;
  206. align-content: flex-start;
  207. }
  208. .webio-tabs > label {
  209. display: inline-block;
  210. padding: .5rem 1rem;
  211. border-bottom: 1px transparent;
  212. cursor: pointer;
  213. margin-bottom: 0!important;
  214. }
  215. .webio-tabs > label:hover {
  216. background-color: #e9ecef;
  217. }
  218. .webio-tabs > .webio-tabs-content {
  219. order: 999;
  220. width: 100%;
  221. border-top: 1px solid #f5f5f5;
  222. padding: 1rem;
  223. display: none
  224. }
  225. .webio-tabs > input[type=radio]:checked + label {
  226. border-bottom: 2px solid #0055bb
  227. }
  228. .webio-tabs > input[type=radio]:checked + label + .webio-tabs-content {
  229. display: block
  230. }
  231. .webio-tabs > input.toggle {
  232. height: 0;
  233. width: 0;
  234. overflow: hidden;
  235. opacity: 0;
  236. position: absolute;
  237. }
  238. .webio-tabs > [type=radio] {
  239. box-sizing: border-box;
  240. padding: 0;
  241. }
  242. /*End of Tabs widget*/
  243. .custom-file-label > span {
  244. overflow: hidden;
  245. width: calc(100% - 6ch - 0.75rem) !important; /* 6ch is for "Browse", 0.75rem is for the padding of "Browse" button */
  246. text-overflow: ellipsis;
  247. white-space: nowrap;
  248. display: inline-block !important;
  249. }
  250. .CodeMirror-fullscreen {
  251. position: fixed;
  252. top: 0; left: 0; right: 0; bottom: 0;
  253. height: auto;
  254. z-index: 9;
  255. }
  256. .pywebio-clickable{
  257. cursor: pointer;
  258. }
  259. /* scrollable widget */
  260. .webio-scrollable{
  261. overflow: auto;
  262. margin-bottom: 10px;
  263. }
  264. .webio-scrollable.scrollable-border{
  265. padding: 10px;
  266. border: 1px solid rgba(0,0,0,.125);
  267. box-shadow: inset 0 0 2px 0 rgba(0,0,0,.1);
  268. }
  269. /* dark theme */
  270. .webio-theme-dark #input-container {
  271. background: #0d1117;
  272. }
  273. .webio-theme-dark #input-container.fixed {
  274. box-shadow: 0px 0px 8px 5px rgb(0 0 0);
  275. }
  276. .webio-theme-dark .footer {
  277. background-color: #0d1117;
  278. border-top: 1px solid #30363d;
  279. }
  280. .webio-theme-dark .webio-tabs {
  281. border: 1px solid #343a40;
  282. }
  283. .webio-theme-dark .webio-tabs > .webio-tabs-content {
  284. border-top: 1px solid #343a40;
  285. }
  286. .webio-theme-dark .webio-tabs > label:hover {
  287. background-color: #000;
  288. }
  289. .webio-theme-dark .webio-tabs > input[type=radio]:checked + label {
  290. border-bottom: 2px solid #0040a1;
  291. }
  292. .webio-theme-dark .scrollable-border{
  293. border: 1px solid #343a40;
  294. }
  295. .webio-theme-dark details{
  296. border: 1px solid #343a40;
  297. }
  298. .webio-theme-dark details>summary{
  299. background-color: #191d21;
  300. }
  301. .webio-theme-dark details[open]>summary{
  302. border-bottom: 1px solid #343a40;
  303. }
  304. /* dark theme end */
  305. /* For range input */
  306. .form-control-range {
  307. display:inline;
  308. width:calc(100% - 40px);
  309. }
  310. .form-control-range-value{
  311. display: inline-block;
  312. max-width: 35px;
  313. white-space: nowrap;
  314. color: #6c757d;
  315. line-height: 14px;
  316. vertical-align: text-top;
  317. }
  318. /* ag-grid datatable */
  319. .webio-datatable{
  320. margin-bottom: 10px;
  321. }
  322. .ag-grid-cell-bar, .ag-grid-tools {
  323. border-left: solid 1px #bdc3c7;
  324. border-right: solid 1px #bdc3c7;
  325. border-bottom: solid 1px #bdc3c7;
  326. font-size: 13px;
  327. line-height: 16px;
  328. }
  329. .ag-grid-cell-bar {
  330. display: none;
  331. padding: 4px 12px;
  332. word-break: break-word;
  333. min-height: 24px;
  334. }
  335. .ag-grid-tools {
  336. display: -webkit-flex; /* Safari */
  337. display: flex;
  338. align-items: center;
  339. min-height: 23px;
  340. font-weight: 600;
  341. font-size: 12px;
  342. opacity: 0;
  343. }
  344. .ag-grid-tools > .grid-status {
  345. display: -webkit-flex; /* Safari */
  346. display: flex;
  347. align-items: center;
  348. flex-shrink: 0;; /* don't compress me when there no more space */
  349. margin: 0 12px;
  350. color: rgba(0, 0, 0, 0.38);
  351. min-width: 170px;
  352. }
  353. .ag-grid-tools .select-count {
  354. padding-right: 8px;
  355. }
  356. .ag-grid-tools > .grid-actions {
  357. flex-grow: 1; /* use left space */
  358. display: -webkit-flex; /* Safari */
  359. display: flex;
  360. flex-wrap: wrap;
  361. justify-content: flex-end;
  362. align-items: center;
  363. }
  364. .ag-grid-tools .sep {
  365. background-color: rgba(189, 195, 199, 0.5);
  366. width: 1px;
  367. height: 14px;
  368. }
  369. .ag-grid-tools .act-btn {
  370. font-weight: 600;
  371. font-size: 12px;
  372. box-shadow: none;
  373. color: #0000008a;
  374. cursor: pointer;
  375. padding: 3px 8px;
  376. border: none;
  377. border-radius: 0;
  378. }
  379. .ag-grid-tools .act-btn:hover {
  380. background-color: #f1f3f4;
  381. }
  382. .ag-grid-tools .act-btn:active {
  383. background-color: #dadada;
  384. }