A clean, Markdown-based publishing platform made for writers. Write together, and build a community. https://writefreely.org
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.
 
 
 
 
 

451 lines
7.1 KiB

  1. body#pad.classic {
  2. header {
  3. display: flex;
  4. justify-content: space-between;
  5. align-items: center;
  6. }
  7. #editor {
  8. top: 4em;
  9. }
  10. #title {
  11. top: 4.25rem;
  12. bottom: unset;
  13. height: auto;
  14. font-weight: bold;
  15. font-size: 2em;
  16. padding-top: 0;
  17. padding-bottom: 0;
  18. border: 0;
  19. }
  20. #tools {
  21. #belt {
  22. float: none;
  23. }
  24. }
  25. #target {
  26. ul {
  27. a {
  28. padding: 0 0.5em !important;
  29. }
  30. }
  31. }
  32. }
  33. .ProseMirror {
  34. position: relative;
  35. height: calc(~"100% - 1.6em");
  36. overflow-y: auto;
  37. box-sizing: border-box;
  38. -moz-box-sizing: border-box;
  39. font-size: 1.2em;
  40. word-wrap: break-word;
  41. white-space: pre-wrap;
  42. -webkit-font-variant-ligatures: none;
  43. font-variant-ligatures: none;
  44. padding: 0.5em 0;
  45. line-height: 1.5;
  46. outline: none;
  47. }
  48. .ProseMirror pre {
  49. white-space: pre-wrap;
  50. }
  51. .ProseMirror li {
  52. position: relative;
  53. }
  54. .ProseMirror-hideselection *::selection {
  55. background: transparent;
  56. }
  57. .ProseMirror-hideselection *::-moz-selection {
  58. background: transparent;
  59. }
  60. .ProseMirror-hideselection {
  61. caret-color: transparent;
  62. }
  63. .ProseMirror-selectednode {
  64. outline: 2px solid #8cf;
  65. }
  66. /* Make sure li selections wrap around markers */
  67. li.ProseMirror-selectednode {
  68. outline: none;
  69. }
  70. li.ProseMirror-selectednode:after {
  71. content: "";
  72. position: absolute;
  73. left: -32px;
  74. right: -2px;
  75. top: -2px;
  76. bottom: -2px;
  77. border: 2px solid #8cf;
  78. pointer-events: none;
  79. }
  80. .ProseMirror-textblock-dropdown {
  81. min-width: 3em;
  82. }
  83. .ProseMirror-menu {
  84. margin: 0 -4px;
  85. line-height: 1;
  86. }
  87. .ProseMirror-tooltip .ProseMirror-menu {
  88. width: -webkit-fit-content;
  89. width: fit-content;
  90. white-space: pre;
  91. }
  92. .ProseMirror-menuitem {
  93. margin-right: 3px;
  94. display: inline-block;
  95. div {
  96. cursor: pointer;
  97. }
  98. }
  99. .ProseMirror-menuseparator {
  100. border-right: 1px solid #ddd;
  101. margin-right: 3px;
  102. }
  103. .ProseMirror-menu-dropdown, .ProseMirror-menu-dropdown-menu {
  104. font-size: 90%;
  105. white-space: nowrap;
  106. }
  107. .ProseMirror-menu-dropdown {
  108. vertical-align: 1px;
  109. cursor: pointer;
  110. position: relative;
  111. padding-right: 15px;
  112. }
  113. .ProseMirror-menu-dropdown-wrap {
  114. padding: 1px 0 1px 4px;
  115. display: inline-block;
  116. position: relative;
  117. }
  118. .ProseMirror-menu-dropdown:after {
  119. content: "";
  120. border-left: 4px solid transparent;
  121. border-right: 4px solid transparent;
  122. border-top: 4px solid currentColor;
  123. opacity: .6;
  124. position: absolute;
  125. right: 4px;
  126. top: calc(50% - 2px);
  127. }
  128. .ProseMirror-menu-dropdown-menu, .ProseMirror-menu-submenu {
  129. position: absolute;
  130. background: white;
  131. color: #666;
  132. border: 1px solid #aaa;
  133. padding: 2px;
  134. }
  135. .ProseMirror-menu-dropdown-menu {
  136. z-index: 15;
  137. min-width: 6em;
  138. }
  139. .ProseMirror-menu-dropdown-item {
  140. cursor: pointer;
  141. padding: 2px 8px 2px 4px;
  142. }
  143. .ProseMirror-menu-dropdown-item:hover {
  144. background: #f2f2f2;
  145. }
  146. .ProseMirror-menu-submenu-wrap {
  147. position: relative;
  148. margin-right: -4px;
  149. }
  150. .ProseMirror-menu-submenu-label:after {
  151. content: "";
  152. border-top: 4px solid transparent;
  153. border-bottom: 4px solid transparent;
  154. border-left: 4px solid currentColor;
  155. opacity: .6;
  156. position: absolute;
  157. right: 4px;
  158. top: calc(50% - 4px);
  159. }
  160. .ProseMirror-menu-submenu {
  161. display: none;
  162. min-width: 4em;
  163. left: 100%;
  164. top: -3px;
  165. }
  166. .ProseMirror-menu-active {
  167. background: #eee;
  168. border-radius: 4px;
  169. }
  170. .ProseMirror-menu-active {
  171. background: #eee;
  172. border-radius: 4px;
  173. }
  174. .ProseMirror-menu-disabled {
  175. opacity: .3;
  176. }
  177. .ProseMirror-menu-submenu-wrap:hover .ProseMirror-menu-submenu, .ProseMirror-menu-submenu-wrap-active .ProseMirror-menu-submenu {
  178. display: block;
  179. }
  180. .ProseMirror-menubar {
  181. position: relative;
  182. min-height: 1em;
  183. color: #666;
  184. padding: 0.5em;
  185. top: 0;
  186. left: 0;
  187. right: 0;
  188. background: rgba(255, 255, 255, 0.8);
  189. z-index: 10;
  190. -moz-box-sizing: border-box;
  191. box-sizing: border-box;
  192. overflow: visible;
  193. }
  194. .ProseMirror-icon {
  195. display: inline-block;
  196. line-height: .8;
  197. vertical-align: -2px; /* Compensate for padding */
  198. padding: 2px 8px;
  199. cursor: pointer;
  200. }
  201. .ProseMirror-menu-disabled.ProseMirror-icon {
  202. cursor: default;
  203. }
  204. .ProseMirror-icon svg {
  205. fill: currentColor;
  206. height: 1em;
  207. }
  208. .ProseMirror-icon span {
  209. vertical-align: text-top;
  210. }
  211. .ProseMirror-gapcursor {
  212. display: none;
  213. pointer-events: none;
  214. position: absolute;
  215. }
  216. .ProseMirror-gapcursor:after {
  217. content: "";
  218. display: block;
  219. position: absolute;
  220. top: -2px;
  221. width: 20px;
  222. border-top: 1px solid black;
  223. animation: ProseMirror-cursor-blink 1.1s steps(2, start) infinite;
  224. }
  225. @keyframes ProseMirror-cursor-blink {
  226. to {
  227. visibility: hidden;
  228. }
  229. }
  230. .ProseMirror-focused .ProseMirror-gapcursor {
  231. display: block;
  232. }
  233. /* Add space around the hr to make clicking it easier */
  234. .ProseMirror-example-setup-style hr {
  235. padding: 2px 10px;
  236. border: none;
  237. margin: 1em 0;
  238. }
  239. .ProseMirror-example-setup-style hr:after {
  240. content: "";
  241. display: block;
  242. height: 1px;
  243. background-color: silver;
  244. line-height: 2px;
  245. }
  246. .ProseMirror ul, .ProseMirror ol {
  247. padding-left: 30px;
  248. }
  249. .ProseMirror blockquote {
  250. padding-left: 1em;
  251. border-left: 3px solid #eee;
  252. margin-left: 0;
  253. margin-right: 0;
  254. }
  255. .ProseMirror-example-setup-style img {
  256. cursor: default;
  257. }
  258. .ProseMirror-prompt {
  259. background: white;
  260. padding: 1em;
  261. border: 1px solid silver;
  262. position: fixed;
  263. border-radius: 0.25em;
  264. z-index: 11;
  265. box-shadow: -.5px 2px 5px rgba(0, 0, 0, .2);
  266. }
  267. .ProseMirror-prompt h5 {
  268. margin: 0 0 0.75em;
  269. font-family: @sansFont;
  270. font-size: 100%;
  271. color: #444;
  272. }
  273. .ProseMirror-prompt input[type="text"],
  274. .ProseMirror-prompt textarea {
  275. background: #eee;
  276. border: none;
  277. outline: none;
  278. }
  279. .ProseMirror-prompt input[type="text"] {
  280. margin: 0.25em 0;
  281. }
  282. .ProseMirror-prompt-close {
  283. position: absolute;
  284. left: 2px;
  285. top: 1px;
  286. color: #666;
  287. border: none;
  288. background: transparent;
  289. padding: 0;
  290. }
  291. .ProseMirror-prompt-close:after {
  292. content: "✕";
  293. font-size: 12px;
  294. }
  295. .ProseMirror-invalid {
  296. background: #ffc;
  297. border: 1px solid #cc7;
  298. border-radius: 4px;
  299. padding: 5px 10px;
  300. position: absolute;
  301. min-width: 10em;
  302. }
  303. .ProseMirror-prompt-buttons {
  304. margin-top: 5px;
  305. display: none;
  306. }
  307. #editor, .editor {
  308. position: fixed;
  309. top: 0;
  310. right: 0;
  311. bottom: 0;
  312. left: 0;
  313. color: black;
  314. background-clip: padding-box;
  315. padding: 5px 0;
  316. margin: 4em auto 23px auto;
  317. }
  318. .ProseMirror p:first-child,
  319. .ProseMirror h1:first-child,
  320. .ProseMirror h2:first-child,
  321. .ProseMirror h3:first-child,
  322. .ProseMirror h4:first-child,
  323. .ProseMirror h5:first-child,
  324. .ProseMirror h6:first-child {
  325. margin-top: 10px;
  326. }
  327. .ProseMirror p {
  328. margin-bottom: 1em;
  329. }
  330. textarea {
  331. width: 100%;
  332. height: 123px;
  333. border: 1px solid silver;
  334. box-sizing: border-box;
  335. -moz-box-sizing: border-box;
  336. padding: 3px 10px;
  337. border: none;
  338. outline: none;
  339. font-family: inherit;
  340. font-size: inherit;
  341. }
  342. .ProseMirror-menubar-wrapper {
  343. height: 100%;
  344. box-sizing: border-box;
  345. }
  346. .ProseMirror-menubar-wrapper, #markdown textarea {
  347. display: block;
  348. margin-bottom: 4px;
  349. }
  350. .editorreadmore {
  351. color: @textLinkColor;
  352. text-decoration: underline;
  353. text-align: center;
  354. width: 100%;
  355. }
  356. @media all and (min-width: 50em) {
  357. #editor {
  358. margin-left: 10%;
  359. margin-right: 10%;
  360. }
  361. }
  362. @media all and (min-width: 60em) {
  363. #editor {
  364. margin-left: 15%;
  365. margin-right: 15%;
  366. }
  367. }
  368. @media all and (min-width: 70em) {
  369. #editor {
  370. margin-left: 20%;
  371. margin-right: 20%;
  372. }
  373. }
  374. @media all and (min-width: 85em) {
  375. #editor {
  376. margin-left: 25%;
  377. margin-right: 25%;
  378. }
  379. }
  380. @media all and (min-width: 105em) {
  381. #editor {
  382. margin-left: 30%;
  383. margin-right: 30%;
  384. }
  385. }