card-design.scss 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847
  1. // card-design
  2. .card-design {
  3. color: $--color-text-dark;
  4. background: $--color-background;
  5. // page-box
  6. .page-box {
  7. // box-shadow: $--shadow-light;
  8. // box-shadow: 0 0 1px #333;
  9. margin-bottom: 10px;
  10. &::before {
  11. content: "";
  12. position: absolute;
  13. width: 100%;
  14. height: 100%;
  15. top: 0;
  16. left: 0;
  17. z-index: 7;
  18. // background-color: rgba($color: #ffffff, $alpha: 0.7);
  19. }
  20. }
  21. .page-column-main {
  22. &.is-active {
  23. &::before,
  24. .page-column-forbid-area {
  25. border-color: $--color-primary;
  26. }
  27. }
  28. &::before {
  29. content: "";
  30. display: block;
  31. position: absolute;
  32. top: 0;
  33. left: 0;
  34. right: 0;
  35. bottom: 0;
  36. z-index: 8;
  37. border: 1px dashed #d0d0d0;
  38. }
  39. }
  40. .topic-element-edit {
  41. .element-item-error {
  42. box-shadow: 0 0 10px $--color-danger;
  43. }
  44. .element-resize {
  45. background-color: #fff;
  46. > .resize-control {
  47. > .control-point,
  48. > .control-line {
  49. display: none;
  50. }
  51. }
  52. &:hover {
  53. > .resize-control {
  54. > .control-line {
  55. display: block;
  56. }
  57. }
  58. }
  59. &-act {
  60. > .resize-control {
  61. > .control-point,
  62. > .control-line {
  63. display: block;
  64. }
  65. }
  66. }
  67. }
  68. .element-resize-compact {
  69. > .resize-control {
  70. > .control-line {
  71. display: block;
  72. }
  73. }
  74. &:hover {
  75. > .resize-control {
  76. > .control-line {
  77. border-color: #617bea;
  78. }
  79. }
  80. }
  81. &.element-resize-act {
  82. > .resize-control {
  83. > .control-line {
  84. border-color: #617bea;
  85. &-left,
  86. &-right {
  87. border-left-style: solid;
  88. }
  89. &-top,
  90. &-bottom {
  91. border-top-style: solid;
  92. }
  93. }
  94. }
  95. }
  96. }
  97. .element-item-topic-number {
  98. position: absolute;
  99. left: -22px;
  100. top: 0;
  101. width: 20px;
  102. height: 20px;
  103. z-index: 99;
  104. line-height: 20px;
  105. font-size: 12px;
  106. text-align: center;
  107. background-color: $--color-primary;
  108. color: #fff;
  109. border-radius: 50% 0 50% 50%;
  110. cursor: pointer;
  111. &:hover {
  112. background-color: $--color-primary-light;
  113. }
  114. }
  115. // 编辑时,小题扩展答题区之间用虚线
  116. .element-item {
  117. &-explain {
  118. &::before {
  119. border-bottom: 1px dashed #333;
  120. }
  121. }
  122. &-type-last {
  123. &::before {
  124. border-bottom: 1px solid #333;
  125. }
  126. }
  127. }
  128. &:last-child {
  129. .element-item {
  130. &::before {
  131. border-bottom: 1px solid #333;
  132. }
  133. }
  134. .element-item-card-head.element-item-type-pre {
  135. &::before {
  136. border-bottom: none;
  137. }
  138. }
  139. }
  140. // elem-pane
  141. .elem-pane {
  142. width: 100%;
  143. height: 100%;
  144. }
  145. }
  146. .page-column-element {
  147. > .element-resize {
  148. width: 100% !important;
  149. }
  150. }
  151. // page-main-outer
  152. .page-main-outer {
  153. z-index: 1;
  154. background-color: rgba($color: #ffffff, $alpha: 0.7);
  155. &-act {
  156. z-index: 19;
  157. }
  158. }
  159. // design-other-pages
  160. .design-other-pages {
  161. position: absolute;
  162. width: 2000px;
  163. left: -9999px;
  164. top: 0;
  165. z-index: 1000;
  166. visibility: hidden;
  167. }
  168. // card-head-sample
  169. .card-head-sample {
  170. position: absolute;
  171. width: 2000px;
  172. left: -9999px;
  173. top: 0;
  174. z-index: 1001;
  175. visibility: hidden;
  176. }
  177. // card-head
  178. .card-head {
  179. &-top {
  180. .el-input > .el-input__inner {
  181. text-align: center;
  182. border-radius: 0;
  183. border: 0;
  184. background-color: transparent;
  185. box-shadow: 0 0 1px #ccc;
  186. color: #000;
  187. padding: 0;
  188. letter-spacing: -1px;
  189. }
  190. }
  191. &-title {
  192. .el-input__inner {
  193. font-size: 24px;
  194. font-weight: bold;
  195. line-height: 33px;
  196. height: 33px;
  197. }
  198. }
  199. &-subtitle {
  200. .el-input__inner {
  201. line-height: 22px;
  202. height: 22px;
  203. padding: 0 10px;
  204. }
  205. }
  206. }
  207. }
  208. .design-header {
  209. position: fixed;
  210. width: 100%;
  211. height: 50px;
  212. top: 0;
  213. left: 0;
  214. z-index: 99;
  215. padding-left: 260px;
  216. background-color: $--color-text-dark;
  217. overflow: hidden;
  218. padding: 10px 20px 10px 260px;
  219. .design-steps {
  220. position: relative;
  221. text-align: center;
  222. height: 30px;
  223. &::after {
  224. content: "";
  225. position: absolute;
  226. width: 100%;
  227. left: 0;
  228. top: 14px;
  229. border-bottom: 1px dashed $--color-text-gray;
  230. z-index: 2;
  231. }
  232. .step-item {
  233. position: absolute;
  234. top: 0;
  235. z-index: 8;
  236. padding: 0 10px;
  237. color: $--color-text-gray;
  238. &::after {
  239. content: "";
  240. position: absolute;
  241. width: 100%;
  242. left: 0;
  243. top: 14px;
  244. border-bottom: 1px solid $--color-text-dark;
  245. z-index: 5;
  246. }
  247. > i {
  248. position: relative;
  249. display: inline-block;
  250. vertical-align: middle;
  251. height: 30px;
  252. width: 30px;
  253. border-radius: 50%;
  254. border: 2px solid $--color-text-gray;
  255. line-height: 26px;
  256. font-weight: bold;
  257. z-index: 8;
  258. }
  259. > span {
  260. position: relative;
  261. display: inline-block;
  262. vertical-align: middle;
  263. margin-left: 10px;
  264. font-weight: bold;
  265. color: #999;
  266. z-index: 8;
  267. }
  268. &:first-child {
  269. left: 0;
  270. padding-left: 0;
  271. }
  272. &:last-child {
  273. right: 0;
  274. padding-right: 0;
  275. }
  276. &:nth-of-type(2) {
  277. left: 33.3%;
  278. transform: translateX(-50%);
  279. }
  280. &:nth-of-type(3) {
  281. left: 66.7%;
  282. transform: translateX(-50%);
  283. }
  284. }
  285. }
  286. }
  287. .design-action {
  288. position: fixed;
  289. width: 240px;
  290. top: 0;
  291. left: 0;
  292. bottom: 0;
  293. z-index: 100;
  294. overflow: auto;
  295. font-size: 14px;
  296. padding: 20px;
  297. background: $--color-white;
  298. border-top-right-radius: $--border-radius-huge;
  299. border-bottom-right-radius: $--border-radius-huge;
  300. .design-logo {
  301. font-size: 20px;
  302. line-height: 40px;
  303. margin-bottom: 30px;
  304. i {
  305. cursor: pointer;
  306. font-weight: 600;
  307. &:hover {
  308. color: $--color-primary;
  309. }
  310. }
  311. }
  312. .action-part {
  313. margin-bottom: 5px;
  314. color: $--color-text-dark-1;
  315. &-title {
  316. padding-bottom: 10px;
  317. border-bottom: 1px solid $--color-border;
  318. }
  319. &-body {
  320. padding: 20px 0;
  321. }
  322. }
  323. // design-action
  324. .type-list {
  325. font-size: 0;
  326. }
  327. .type-item {
  328. font-size: 14px;
  329. display: inline-block;
  330. vertical-align: top;
  331. width: 50%;
  332. text-align: center;
  333. margin-bottom: 10px;
  334. border-radius: 10px;
  335. cursor: pointer;
  336. &:nth-of-type(even) {
  337. padding-left: 5px;
  338. }
  339. &:nth-of-type(odd) {
  340. padding-right: 5px;
  341. }
  342. .el-button {
  343. width: 100%;
  344. font-size: 14px;
  345. }
  346. i {
  347. margin-right: 2px;
  348. }
  349. }
  350. }
  351. .design-main {
  352. padding: 70px 20px 20px 260px;
  353. position: absolute;
  354. top: 0;
  355. left: 0;
  356. bottom: 0;
  357. right: 0;
  358. overflow: auto;
  359. background-color: $--color-background;
  360. }
  361. .design-control {
  362. position: fixed;
  363. top: 50px;
  364. left: 240px;
  365. right: 0;
  366. height: 70px;
  367. z-index: 99;
  368. background-color: $--color-background;
  369. display: flex;
  370. align-items: center;
  371. justify-content: space-between;
  372. .control-right {
  373. padding: 20px 20px 20px 0;
  374. width: 240px;
  375. text-align: right;
  376. flex-grow: 0;
  377. .el-button {
  378. width: 60px;
  379. }
  380. }
  381. .control-left {
  382. padding: 20px 0 20px 20px;
  383. white-space: nowrap;
  384. overflow-y: hidden;
  385. overflow-x: auto;
  386. flex-grow: 2;
  387. }
  388. }
  389. .design-body {
  390. position: relative;
  391. min-height: 1242px;
  392. padding-top: 50px;
  393. }
  394. // topic-list
  395. .topic-list {
  396. position: absolute;
  397. top: -2000px;
  398. left: -5000px;
  399. z-index: auto;
  400. visibility: hidden;
  401. .element-item-card-head {
  402. width: 100% !important;
  403. height: auto !important;
  404. }
  405. .page-main-inner {
  406. overflow: hidden;
  407. }
  408. }
  409. // tool-tips
  410. .tool-tips {
  411. color: $--color-text-dark-1;
  412. }
  413. // page-prop-edit
  414. .page-prop-edit {
  415. .el-form-item {
  416. margin-bottom: 5px;
  417. }
  418. .el-form-item__label,
  419. .el-checkbox {
  420. color: $--color-text-dark-1;
  421. }
  422. .el-form-item__label {
  423. padding-right: 10px;
  424. }
  425. .column-btn {
  426. padding: 0;
  427. border: none !important;
  428. vertical-align: middle;
  429. }
  430. .topicno-list {
  431. font-size: 0;
  432. line-height: 32px;
  433. li {
  434. display: inline-block;
  435. vertical-align: middle;
  436. margin: 0 5px 0 0;
  437. width: 20px;
  438. height: 20px;
  439. line-height: 20px;
  440. text-align: center;
  441. font-size: 12px;
  442. border-radius: 5px;
  443. background-color: $--color-primary;
  444. color: #fff;
  445. }
  446. }
  447. }
  448. // element-prop-edit
  449. .edit-dialog {
  450. .el-input-split {
  451. position: relative;
  452. display: inline-block;
  453. margin: 3px 10px;
  454. width: 10px;
  455. border-bottom: 2px solid #dddddd;
  456. }
  457. .el-input-number.is-without-controls {
  458. .el-input__inner {
  459. padding-left: 5px;
  460. padding-right: 5px;
  461. }
  462. }
  463. }
  464. // element-tier-edit
  465. .element-tier-edit {
  466. .tier-menu {
  467. font-size: 0;
  468. &-item {
  469. display: inline-block;
  470. vertical-align: top;
  471. height: 26px;
  472. line-height: 26px;
  473. padding: 0 10px;
  474. font-size: 13px;
  475. cursor: pointer;
  476. border: 1px solid #eff0f5;
  477. width: 25%;
  478. text-align: center;
  479. border-top-left-radius: 3px;
  480. border-top-right-radius: 3px;
  481. &:hover {
  482. color: $--color-primary;
  483. }
  484. &.is-active {
  485. background-color: #eff0f5;
  486. color: #333;
  487. }
  488. }
  489. }
  490. .tier-list {
  491. height: 240px;
  492. overflow: auto;
  493. background-color: #eff0f5;
  494. position: relative;
  495. padding: 3px 0;
  496. border-bottom-left-radius: 3px;
  497. border-bottom-right-radius: 3px;
  498. }
  499. .tier-item {
  500. position: relative;
  501. padding: 0 5px;
  502. &.after-drop {
  503. &::after {
  504. content: "";
  505. display: block;
  506. position: absolute;
  507. width: 100%;
  508. border-bottom: 2px solid $--color-text-dark;
  509. bottom: -2px;
  510. left: 0;
  511. z-index: 9;
  512. }
  513. }
  514. &.before-drop {
  515. &::before {
  516. content: "";
  517. display: block;
  518. position: absolute;
  519. width: 100%;
  520. border-top: 2px solid $--color-text-dark;
  521. top: -2px;
  522. left: 0;
  523. z-index: 9;
  524. }
  525. }
  526. &-cont {
  527. padding: 5px 10px;
  528. background-color: #fff;
  529. border: 1px solid #e0e0e0;
  530. border-radius: 3px;
  531. height: 30px;
  532. line-height: 20px;
  533. font-size: 13px;
  534. overflow: hidden;
  535. text-overflow: ellipsis;
  536. white-space: nowrap;
  537. cursor: pointer;
  538. &:hover {
  539. color: $--color-primary;
  540. }
  541. &.is-active {
  542. border-color: $--color-primary;
  543. color: $--color-primary;
  544. }
  545. }
  546. }
  547. }
  548. // right-menu-body
  549. .right-menu-body {
  550. border: 1px solid #cccccc;
  551. border-radius: 5px;
  552. overflow: hidden;
  553. background-color: #fff;
  554. font-size: 14px;
  555. color: #666666;
  556. box-shadow: 5px 5px 4px 0px rgba(0, 0, 0, 0.1);
  557. li {
  558. padding: 6px;
  559. font-weight: 400;
  560. cursor: pointer;
  561. &:hover {
  562. background-color: #f6f6f6;
  563. color: $--color-primary;
  564. }
  565. &.li-danger:hover {
  566. color: $--color-danger;
  567. }
  568. &:not(:last-child) {
  569. border-bottom: 1px solid #dddddd;
  570. }
  571. }
  572. }
  573. // design-preview-frame
  574. .design-preview-frame {
  575. position: absolute;
  576. width: 1000px;
  577. height: 600px;
  578. left: -9999px;
  579. top: 0;
  580. z-index: 1001;
  581. visibility: hidden;
  582. }
  583. // card custom-select
  584. .custom-select {
  585. width: 100%;
  586. .select-preview {
  587. height: 32px;
  588. line-height: 30px;
  589. border: 1px solid #e0e0e0;
  590. border-radius: 5px;
  591. position: relative;
  592. overflow: hidden;
  593. cursor: pointer;
  594. &:hover {
  595. border-color: #b0b0b0;
  596. }
  597. &-main {
  598. padding: 0 30px 0 15px;
  599. }
  600. &-icon {
  601. position: absolute;
  602. top: 0;
  603. right: 0;
  604. width: 30px;
  605. height: 100%;
  606. background-color: #fff;
  607. text-align: center;
  608. }
  609. }
  610. }
  611. // color-select
  612. .color-item {
  613. display: inline-block;
  614. vertical-align: middle;
  615. width: 100px;
  616. height: 26px;
  617. }
  618. .color-menu .el-dropdown-menu__item {
  619. line-height: 30px;
  620. padding: 0 15px;
  621. }
  622. // line-style-select
  623. .style-item {
  624. display: inline-block;
  625. vertical-align: middle;
  626. width: 100px;
  627. border-bottom-width: 2px;
  628. border-bottom-color: #000;
  629. }
  630. .line-style-menu .el-dropdown-menu__item {
  631. line-height: 24px;
  632. padding: 0 10px;
  633. }
  634. // line-width-select
  635. .width-item {
  636. display: inline-block;
  637. vertical-align: middle;
  638. width: 100px;
  639. > i {
  640. display: inline-block;
  641. vertical-align: middle;
  642. width: 65px;
  643. border-bottom: 1pt solid #000;
  644. }
  645. > span {
  646. display: block;
  647. float: right;
  648. line-height: 28px;
  649. width: 40px;
  650. margin-right: -10px;
  651. text-align: center;
  652. }
  653. }
  654. .line-width-menu .el-dropdown-menu__item {
  655. line-height: 24px;
  656. padding: 0 10px;
  657. }
  658. .edit-dialog {
  659. .el-dialog__footer {
  660. text-align: right;
  661. }
  662. }
  663. // paper-params
  664. .paper-params {
  665. .params-dialog-title {
  666. font-size: 16px;
  667. > span {
  668. font-size: 14px;
  669. margin-left: 24px;
  670. color: $--color-text-gray-1;
  671. }
  672. }
  673. .params-main {
  674. margin-top: -10px;
  675. padding: 0 10px;
  676. }
  677. .params-head {
  678. margin-bottom: 20px;
  679. }
  680. .params-part {
  681. margin: 15px 0;
  682. }
  683. .params-title {
  684. margin-bottom: 10px;
  685. }
  686. .params-subtitle {
  687. margin-bottom: 10px;
  688. > span {
  689. display: inline-block;
  690. vertical-align: middle;
  691. &:first-child {
  692. margin-right: 20px;
  693. }
  694. }
  695. .el-input-number {
  696. width: 60px;
  697. margin: 0 5px;
  698. }
  699. }
  700. .param-sum-score {
  701. color: $--color-danger;
  702. }
  703. }
  704. // element-guide-lines
  705. .element-guide-lines {
  706. .guide-line {
  707. position: absolute;
  708. z-index: 999;
  709. &-x {
  710. border-bottom: 1px solid $--color-success;
  711. }
  712. &-y {
  713. border-left: 1px solid $--color-success;
  714. }
  715. }
  716. }
  717. // card-free-design
  718. .card-free-design {
  719. .page-column-main {
  720. overflow: hidden;
  721. }
  722. .topic-design {
  723. position: absolute;
  724. }
  725. .design-header {
  726. &-cont {
  727. height: 100%;
  728. }
  729. .btn-help {
  730. font-size: 20px;
  731. padding: 0;
  732. }
  733. }
  734. .design-action {
  735. .action-part {
  736. &-title {
  737. padding-bottom: 5px;
  738. }
  739. &-body {
  740. padding: 10px 0;
  741. }
  742. }
  743. }
  744. .control-left {
  745. .el-button {
  746. position: relative;
  747. }
  748. .page-delete {
  749. display: block;
  750. position: absolute;
  751. top: 0;
  752. right: 0;
  753. margin-top: -8px;
  754. margin-right: -8px;
  755. font-size: 14px;
  756. color: $--color-danger;
  757. cursor: pointer;
  758. &:hover {
  759. color: mix(#000, $--color-danger, 20%);
  760. }
  761. }
  762. }
  763. }
  764. // shortcut-key-spin
  765. .shortcut-key-spin {
  766. position: relative;
  767. display: inline-block;
  768. vertical-align: middle;
  769. border-radius: 5px;
  770. padding: 0 5px;
  771. background-color: $--color-text-gray-5;
  772. color: $--color-text-dark-1;
  773. &:not(:first-child) {
  774. margin-left: 20px;
  775. &::before {
  776. content: "+";
  777. display: block;
  778. position: absolute;
  779. left: -15px;
  780. top: 50%;
  781. transform: translateY(-50%);
  782. }
  783. }
  784. }
  785. // element
  786. .edit-text {
  787. .el-textarea__inner {
  788. font-family: "Times New Roman", "宋体", "宋体-简", Arial, sans-serif;
  789. }
  790. }