card-preview.scss 31 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699
  1. // card-preview
  2. .card-preview {
  3. padding: 10px 0;
  4. background-color: #f0f0f0;
  5. color: #000;
  6. .page-box {
  7. margin: 10px auto;
  8. box-shadow: 0 0 4px #ddd;
  9. }
  10. }
  11. .card-print {
  12. padding: 0;
  13. .page-box {
  14. margin: 0 auto;
  15. box-shadow: none;
  16. page-break-after: always;
  17. }
  18. // 印刷模式:隐藏客观题强调标记
  19. .elem-fill-question-first {
  20. &::before {
  21. display: none;
  22. }
  23. }
  24. .elem-fill-question .option-item,
  25. .elem-fill-number .fill-number-option,
  26. .card-head-body .head-stdno .stdno-fill-option,
  27. .page-number-rect-list li,
  28. .card-head-body .head-dynamic-rect {
  29. border-width: 0.5pt;
  30. }
  31. .elem-fill-question .option-item {
  32. line-height: 9px;
  33. }
  34. .package-number {
  35. display: block !important;
  36. }
  37. }
  38. // page-box
  39. .page-box {
  40. position: relative;
  41. background: #fff;
  42. margin: 0 auto;
  43. font-weight: normal;
  44. font-family: "宋体", "宋体-简", Arial, sans-serif;
  45. .package-number {
  46. position: absolute;
  47. width: 400px;
  48. height: 40px;
  49. padding: 0 20px;
  50. top: 10px;
  51. left: 54%;
  52. text-align: center;
  53. z-index: 99;
  54. display: none;
  55. img {
  56. display: inline-block;
  57. height: 28px;
  58. width: auto;
  59. border: none;
  60. }
  61. p {
  62. line-height: 1;
  63. font-size: 12px;
  64. margin: 0;
  65. }
  66. }
  67. .page-main {
  68. height: 100%;
  69. position: relative;
  70. white-space: nowrap;
  71. margin: 0 -10px;
  72. font-size: 0;
  73. &-2 {
  74. .page-column {
  75. width: 50%;
  76. }
  77. }
  78. &-3 {
  79. .page-column {
  80. width: 33.33%;
  81. }
  82. }
  83. &-4 {
  84. .page-column {
  85. width: 25%;
  86. }
  87. }
  88. }
  89. &-A3 {
  90. width: 1586px;
  91. height: 1122px;
  92. }
  93. &-A4 {
  94. width: 793px;
  95. height: 1122px;
  96. .page-main {
  97. &-inner {
  98. padding: 60px 45px;
  99. }
  100. }
  101. }
  102. &-B4 {
  103. // w:353mm,h:250mm
  104. width: 1334px;
  105. height: 945px;
  106. .page-main {
  107. &-inner {
  108. padding: 60px;
  109. }
  110. }
  111. }
  112. &-8K {
  113. // w:390mm,h:270mm
  114. width: 1474px;
  115. height: 1020px;
  116. }
  117. &-less {
  118. .page-number-rect {
  119. display: none;
  120. }
  121. }
  122. }
  123. // 分栏间距,默认20px
  124. // page-main-inner
  125. .page-main-inner {
  126. position: absolute;
  127. width: 100%;
  128. height: 100%;
  129. top: 0;
  130. left: 0;
  131. padding: 60px 80px;
  132. z-index: 9;
  133. font-size: 0;
  134. }
  135. // page-main-outer
  136. .page-main-outer {
  137. position: absolute;
  138. top: 0;
  139. left: 0;
  140. right: 0;
  141. bottom: 0;
  142. z-index: 7;
  143. background-color: transparent;
  144. overflow: hidden;
  145. }
  146. .page-column {
  147. display: inline-block;
  148. vertical-align: middle;
  149. position: relative;
  150. height: 100%;
  151. width: 100%;
  152. font-size: 14px;
  153. padding: 0 10px;
  154. &-forbid-area {
  155. position: absolute;
  156. top: 0;
  157. left: 0;
  158. bottom: 0;
  159. right: 0;
  160. z-index: 1;
  161. border: 1px solid #000;
  162. overflow: hidden;
  163. > p {
  164. padding: 20px;
  165. position: absolute;
  166. width: 260px;
  167. height: 82px;
  168. top: 50%;
  169. left: 50%;
  170. margin-top: -41px;
  171. margin-left: -130px;
  172. z-index: 9;
  173. font-weight: bold;
  174. font-size: 30px;
  175. color: #333;
  176. background-color: #fff;
  177. text-align: center;
  178. }
  179. }
  180. &-main {
  181. position: relative;
  182. height: 100%;
  183. }
  184. &-body {
  185. position: absolute;
  186. top: 0;
  187. bottom: 0;
  188. left: 0;
  189. right: 0;
  190. z-index: 9;
  191. }
  192. &-element {
  193. .element-item {
  194. position: relative;
  195. &-width {
  196. width: 100% !important;
  197. }
  198. &::before {
  199. content: "";
  200. position: absolute;
  201. width: 100%;
  202. height: 100%;
  203. top: 0;
  204. left: 0;
  205. box-sizing: border-box;
  206. z-index: 2;
  207. border: 1px solid #000;
  208. border-top: 0;
  209. }
  210. > div {
  211. z-index: 9;
  212. position: relative;
  213. }
  214. &-card-head {
  215. &::before {
  216. border: 0;
  217. }
  218. }
  219. &-topic-head {
  220. &::before {
  221. border: 0;
  222. }
  223. }
  224. &-fill-question,
  225. &-fill-line {
  226. &::before {
  227. border-bottom: 0;
  228. }
  229. }
  230. // 预览时,小题扩展答题区之间隐藏分割线
  231. &-explain {
  232. &::before {
  233. border-bottom-color: transparent;
  234. }
  235. }
  236. &-type-last {
  237. &::before {
  238. border-bottom: 1px solid #000;
  239. }
  240. }
  241. }
  242. &:last-child {
  243. .element-item {
  244. &::before {
  245. border-bottom: 1px solid #000;
  246. }
  247. }
  248. .element-item-card-head.element-item-type-pre {
  249. &::before {
  250. border-bottom: none;
  251. }
  252. }
  253. }
  254. }
  255. }
  256. // locator
  257. .page-locator {
  258. position: absolute;
  259. left: 80px;
  260. right: 80px;
  261. height: 16px;
  262. z-index: 8;
  263. &-top {
  264. top: 30px;
  265. }
  266. &-bottom {
  267. bottom: 30px;
  268. }
  269. &-item {
  270. position: absolute;
  271. width: 24px;
  272. border-bottom: 16px solid #000;
  273. top: 0;
  274. &:nth-of-type(1) {
  275. left: 0;
  276. }
  277. &:nth-of-type(2) {
  278. right: 96px;
  279. }
  280. }
  281. }
  282. .page-box-1 {
  283. .page-locator {
  284. &-bottom {
  285. .page-locator-item:nth-of-type(1) {
  286. right: 0;
  287. left: auto;
  288. }
  289. }
  290. &-item {
  291. &:nth-of-type(1) {
  292. left: 96px;
  293. }
  294. &:nth-of-type(2) {
  295. right: 0;
  296. }
  297. }
  298. }
  299. }
  300. // page-number
  301. .page-number {
  302. position: absolute;
  303. bottom: 30px;
  304. &-rect {
  305. left: 25%;
  306. transform: translateX(-50%);
  307. -webkit-transform: translateX(-50%);
  308. }
  309. &-rect-list {
  310. font-size: 0;
  311. li {
  312. display: inline-block;
  313. vertical-align: top;
  314. font-size: 14px;
  315. width: 24px;
  316. height: 16px;
  317. border: 1px solid #000;
  318. margin-right: 10px;
  319. &.rect-li-act {
  320. background-color: #000;
  321. }
  322. }
  323. }
  324. &-text {
  325. right: 25%;
  326. }
  327. &-text-cont {
  328. height: 16px;
  329. line-height: 16px;
  330. }
  331. }
  332. .page-box-A4 {
  333. .page-number-rect {
  334. left: 50%;
  335. }
  336. }
  337. // course-barcode
  338. .course-barcode {
  339. position: absolute;
  340. width: 400px;
  341. height: 40px;
  342. padding: 0 20px;
  343. top: 10px;
  344. left: 50%;
  345. margin-left: -400px;
  346. text-align: center;
  347. img {
  348. display: inline-block;
  349. height: 28px;
  350. width: auto;
  351. border: none;
  352. }
  353. img[src=""] {
  354. display: none;
  355. }
  356. p {
  357. line-height: 1;
  358. font-size: 12px;
  359. margin: 0;
  360. }
  361. }
  362. .page-box-A4 {
  363. .course-barcode {
  364. left: 120px;
  365. margin-left: 0;
  366. }
  367. .package-number {
  368. left: 300px;
  369. margin-left: 0;
  370. }
  371. }
  372. // elem
  373. .elem {
  374. &-title {
  375. padding: 10px;
  376. font-size: 14px;
  377. font-weight: bold;
  378. color: rgba(0, 0, 0, 1);
  379. line-height: 1;
  380. white-space: normal;
  381. }
  382. &-body {
  383. padding: 10px;
  384. }
  385. }
  386. // grid
  387. .grid-container {
  388. margin-left: -10px;
  389. margin-right: -10px;
  390. }
  391. .grid-row {
  392. display: table;
  393. width: 100%;
  394. border-spacing: 10px 0;
  395. border-collapse: separate;
  396. &:nth-of-type(2) {
  397. margin-top: 10px;
  398. }
  399. .grid-col {
  400. display: table-cell;
  401. width: 50%;
  402. vertical-align: top;
  403. border: 1px solid #000;
  404. &-dash {
  405. border-style: dashed;
  406. vertical-align: middle;
  407. }
  408. }
  409. }
  410. // card-head
  411. .card-head {
  412. &-top {
  413. text-align: center;
  414. color: #000;
  415. }
  416. &-title {
  417. font-size: 24px;
  418. font-weight: bold;
  419. overflow: hidden;
  420. > h1 {
  421. line-height: 33px;
  422. white-space: nowrap;
  423. letter-spacing: -1px;
  424. }
  425. }
  426. &-subtitle {
  427. height: 44px;
  428. font-size: 14px;
  429. overflow: hidden;
  430. white-space: normal;
  431. margin-bottom: 10px;
  432. p {
  433. padding: 0 10px;
  434. line-height: 22px;
  435. height: 22px;
  436. white-space: pre;
  437. }
  438. }
  439. &-body {
  440. font-weight: normal;
  441. .el-col {
  442. padding-top: 5px;
  443. padding-bottom: 5px;
  444. }
  445. &-spin {
  446. padding: 5px 12px;
  447. white-space: normal;
  448. word-break: break-all;
  449. }
  450. .stdinfo-item {
  451. height: 30px;
  452. line-height: 30px;
  453. position: relative;
  454. overflow: hidden;
  455. &::after {
  456. content: "";
  457. display: block;
  458. position: absolute;
  459. width: 100%;
  460. border-bottom: 1px solid #000;
  461. bottom: 6px;
  462. left: 0;
  463. z-index: 1;
  464. }
  465. > span {
  466. z-index: 2;
  467. display: block;
  468. position: relative;
  469. font-size: 14px;
  470. &:first-child {
  471. float: left;
  472. background-color: #fff;
  473. text-align: justify;
  474. font-size: 0px;
  475. & > i {
  476. font-size: 14px;
  477. }
  478. &::after {
  479. content: "";
  480. display: inline-block;
  481. width: 100%;
  482. height: 0;
  483. line-height: 0;
  484. }
  485. }
  486. &:nth-of-type(2) {
  487. float: left;
  488. width: 20px;
  489. background-color: #fff;
  490. }
  491. &:last-child {
  492. margin-left: 80px;
  493. height: 100%;
  494. }
  495. }
  496. }
  497. .head-stdno {
  498. height: 100%;
  499. padding: 0;
  500. .stdno-empty {
  501. min-height: 130px;
  502. font-weight: bold;
  503. letter-spacing: 3px;
  504. text-align: center;
  505. position: relative;
  506. > p {
  507. position: absolute;
  508. left: 0;
  509. width: 100%;
  510. top: 50%;
  511. transform: translateY(-50%);
  512. -webkit-transform: translateY(-50%);
  513. }
  514. }
  515. .stdno-fill {
  516. min-height: 240px;
  517. height: 100%;
  518. position: relative;
  519. &-rect {
  520. font-size: 0;
  521. height: 27px;
  522. border-bottom: 1px solid #000;
  523. }
  524. &-number {
  525. display: inline-block;
  526. vertical-align: top;
  527. width: 7.692%;
  528. height: 100%;
  529. &:not(:last-child) {
  530. border-right: 1px solid #000;
  531. }
  532. }
  533. &-head {
  534. position: absolute;
  535. width: 100%;
  536. height: 51px;
  537. top: 0;
  538. left: 0;
  539. z-index: 9;
  540. > h5 {
  541. border-bottom: 1px solid #000;
  542. line-height: 24px;
  543. font-size: 14px;
  544. font-weight: bold;
  545. text-align: center;
  546. }
  547. }
  548. &-body {
  549. position: absolute;
  550. top: 0;
  551. bottom: 0;
  552. padding-top: 51px;
  553. display: table;
  554. width: 100%;
  555. }
  556. &-list {
  557. display: table-cell;
  558. width: 7.692%;
  559. padding: 1px 0;
  560. }
  561. &-option {
  562. margin: 8px auto;
  563. width: 18px;
  564. height: 10px;
  565. font-size: 12px;
  566. line-height: 8px;
  567. text-align: center;
  568. color: #000;
  569. // border-rect
  570. border: 1px solid #000;
  571. font-family: "Times New Roman", Arial, sans-serif;
  572. > i {
  573. display: inline-block;
  574. transform: scale(0.67, 0.67);
  575. -webkit-transform: scale(0.67, 0.67);
  576. }
  577. }
  578. }
  579. .stdno-auto {
  580. &-barcode {
  581. height: 70px;
  582. text-align: center;
  583. > img {
  584. display: block;
  585. height: 50px;
  586. width: 300px;
  587. margin: 0 auto;
  588. }
  589. > p {
  590. line-height: 20px;
  591. }
  592. }
  593. }
  594. }
  595. .head-notice {
  596. > h4 {
  597. font-weight: normal;
  598. margin-bottom: 8px;
  599. line-height: 20px;
  600. }
  601. &-cont {
  602. line-height: 1.5;
  603. font-size: 12px;
  604. margin-bottom: 5px;
  605. > span {
  606. display: block;
  607. &:first-child {
  608. width: 20px;
  609. white-space: nowrap;
  610. float: left;
  611. }
  612. &:last-child {
  613. margin-left: 20px;
  614. }
  615. }
  616. }
  617. &-exam-number-fill {
  618. span {
  619. display: inline;
  620. &:first-child {
  621. float: none;
  622. }
  623. &:last-child {
  624. margin: 0;
  625. }
  626. }
  627. }
  628. }
  629. .head-dynamic {
  630. padding: 0;
  631. font-size: 12px;
  632. border-spacing: 0;
  633. border-collapse: collapse;
  634. &-part:not(:last-child) {
  635. border-bottom: 1px solid #000;
  636. }
  637. &-write {
  638. padding: 5px 12px;
  639. .stdinfo-item {
  640. margin-bottom: 0;
  641. }
  642. > p {
  643. line-height: 18px;
  644. }
  645. }
  646. &-missfill {
  647. display: table;
  648. width: 100%;
  649. }
  650. &-miss {
  651. padding: 10px;
  652. display: table-cell;
  653. vertical-align: middle;
  654. &:nth-of-type(2) {
  655. border-left: 1px solid #000;
  656. }
  657. span {
  658. display: block;
  659. }
  660. .head-dynamic-content {
  661. height: 14px;
  662. line-height: 14px;
  663. }
  664. .dynamic-miss-title {
  665. width: 54px;
  666. float: left;
  667. }
  668. .dynamic-miss-body {
  669. margin-left: 54px;
  670. height: 14px;
  671. text-align: center;
  672. font-size: 0;
  673. }
  674. }
  675. &-fill {
  676. padding: 10px;
  677. p {
  678. display: inline-block;
  679. vertical-align: middle;
  680. line-height: 18px;
  681. word-wrap: normal;
  682. &:first-child {
  683. margin-right: 20px;
  684. }
  685. > span,
  686. > i {
  687. display: inline-block;
  688. vertical-align: middle;
  689. box-sizing: border-box;
  690. }
  691. &:first-child {
  692. i {
  693. width: 28px;
  694. height: 14px;
  695. background-color: #000;
  696. }
  697. }
  698. &:last-child {
  699. > i {
  700. width: 28px;
  701. height: 14px;
  702. border: 1px solid #000;
  703. font-size: 14px;
  704. font-weight: bold;
  705. margin-right: 6px;
  706. line-height: 12px;
  707. text-align: center;
  708. &:last-child {
  709. margin-right: 0;
  710. }
  711. // wkhtmltopdf 工具无法渲染如下样式:
  712. // &:nth-of-type(1) {
  713. // position: relative;
  714. // &::before {
  715. // content: "";
  716. // display: block;
  717. // position: absolute;
  718. // left: 30%;
  719. // top: 1px;
  720. // height: 5px;
  721. // width: 11px;
  722. // transform: rotate(-45deg);
  723. // border-left: 1px solid #000;
  724. // border-bottom: 1px solid #000;
  725. // }
  726. // }
  727. // &:nth-of-type(2) {
  728. // position: relative;
  729. // &::before {
  730. // content: "";
  731. // display: block;
  732. // position: absolute;
  733. // left: 7px;
  734. // top: 5px;
  735. // width: 11px;
  736. // transform: rotate(-45deg);
  737. // transform-origin: center center;
  738. // border-bottom: 1px solid #000;
  739. // }
  740. // &::after {
  741. // content: "";
  742. // display: block;
  743. // position: absolute;
  744. // left: 8px;
  745. // top: 5px;
  746. // width: 11px;
  747. // transform: rotate(45deg);
  748. // transform-origin: center center;
  749. // border-bottom: 1px solid #000;
  750. // }
  751. // }
  752. &:nth-of-type(3) {
  753. &::before {
  754. content: "";
  755. display: inline-block;
  756. vertical-align: top;
  757. margin-left: -5px;
  758. height: 100%;
  759. width: 5px;
  760. background-color: #000;
  761. }
  762. }
  763. &:nth-of-type(4) {
  764. &::before {
  765. content: "";
  766. display: inline-block;
  767. margin-top: 1px;
  768. width: 10px;
  769. height: 10px;
  770. border-radius: 50%;
  771. background-color: #000;
  772. }
  773. }
  774. }
  775. }
  776. }
  777. }
  778. &-rect {
  779. display: inline-block;
  780. vertical-align: middle;
  781. width: 24px;
  782. height: 12px;
  783. // border-rect
  784. border: 1px solid #000;
  785. font-size: 12px;
  786. text-align: center;
  787. line-height: 10px;
  788. color: #000;
  789. margin: 0 5px;
  790. font-family: "Times New Roman", Arial, sans-serif;
  791. > i {
  792. display: inline-block;
  793. transform: scale(0.67, 0.67);
  794. -webkit-transform: scale(0.67, 0.67);
  795. }
  796. }
  797. &-aorb {
  798. display: table;
  799. width: 100%;
  800. .dynamic-aorb-item {
  801. display: table-cell;
  802. vertical-align: middle;
  803. }
  804. &-fill {
  805. .dynamic-aorb-item:first-child {
  806. border: none;
  807. }
  808. }
  809. .dynamic-aorb-title {
  810. width: 40%;
  811. padding: 10px;
  812. }
  813. .dynamic-aorb-info {
  814. width: 60%;
  815. font-size: 16px;
  816. position: relative;
  817. overflow: hidden;
  818. text-align: center;
  819. .dynamic-aorb-content {
  820. position: absolute;
  821. top: 50%;
  822. left: 0;
  823. width: 100%;
  824. transform: translateY(-50%);
  825. -webkit-transform: translateY(-50%);
  826. z-index: auto;
  827. }
  828. }
  829. .dynamic-aorb-barcode {
  830. img {
  831. display: block;
  832. position: relative;
  833. margin: 0 auto;
  834. width: 200px;
  835. height: 26px;
  836. padding: 7px 0;
  837. }
  838. }
  839. .dynamic-aorb-rects {
  840. width: 60%;
  841. padding: 16px 10px;
  842. text-align: center;
  843. }
  844. .head-dynamic-rect {
  845. margin: 0 30px;
  846. &:first-child {
  847. margin-left: 0;
  848. }
  849. &:last-child {
  850. margin-right: 0;
  851. }
  852. }
  853. }
  854. }
  855. }
  856. &-part {
  857. border: 1px solid #000;
  858. &:not(:last-child) {
  859. margin-bottom: 10px;
  860. }
  861. }
  862. &-normal {
  863. .head-dynamic {
  864. &-1 {
  865. .head-dynamic-part {
  866. height: 100%;
  867. }
  868. }
  869. }
  870. }
  871. &-narrow {
  872. .head-stdno {
  873. height: 138px;
  874. .stdno-auto {
  875. position: relative;
  876. top: 50%;
  877. margin-top: -40px;
  878. }
  879. }
  880. }
  881. &-handle {
  882. &.card-head-narrow {
  883. .head-stdno {
  884. height: 242px;
  885. }
  886. }
  887. }
  888. }
  889. // card-head-body-auto-resize
  890. .card-head-body-auto-resize {
  891. margin-left: -5px;
  892. margin-right: -5px;
  893. overflow: hidden;
  894. &.col-item-auto-height {
  895. .card-head-body-spin {
  896. height: auto;
  897. }
  898. }
  899. .head-dynamic-2 {
  900. .head-dynamic-part {
  901. height: auto;
  902. }
  903. }
  904. .rect-col {
  905. padding: 5px;
  906. &:first-child {
  907. float: left;
  908. width: 50%;
  909. }
  910. &:last-child {
  911. float: right;
  912. width: 50%;
  913. }
  914. &-item {
  915. border: 1px solid #000;
  916. &:nth-of-type(2) {
  917. margin-top: 10px;
  918. }
  919. &-none {
  920. border: none;
  921. margin: 0 !important;
  922. }
  923. }
  924. }
  925. }
  926. // elem-topic-head
  927. .elem-topic-head {
  928. text-align: center;
  929. .elem-body {
  930. padding: 0;
  931. border: 1px solid #000;
  932. }
  933. &-pad {
  934. padding-top: 10px;
  935. }
  936. &-empty {
  937. .elem-body {
  938. border-top: none;
  939. }
  940. }
  941. h3 {
  942. font-size: 16px;
  943. height: 29px;
  944. line-height: 28px;
  945. border-bottom: 1px dotted #000;
  946. font-weight: normal;
  947. }
  948. p {
  949. font-size: 12px;
  950. height: 22px;
  951. line-height: 22px;
  952. white-space: nowrap;
  953. overflow: hidden;
  954. // text-overflow: ellipsis;
  955. }
  956. }
  957. // elem-line
  958. .elem-line-horizontal {
  959. height: 100%;
  960. line-height: 30px;
  961. .line-body {
  962. display: inline-block;
  963. vertical-align: middle;
  964. width: 100%;
  965. border-bottom: 1px solid #000;
  966. }
  967. }
  968. .elem-line-vertical {
  969. height: 100%;
  970. text-align: center;
  971. .line-body {
  972. display: inline-block;
  973. vertical-align: top;
  974. height: 100%;
  975. border-left: 1px solid #000;
  976. }
  977. }
  978. // elem-lines
  979. .elem-lines {
  980. .line-item {
  981. display: inline-block;
  982. vertical-align: top;
  983. }
  984. }
  985. // elem-rect
  986. .elem-rect {
  987. .rect-body {
  988. position: absolute;
  989. width: 100%;
  990. height: 100%;
  991. top: 0;
  992. left: 0;
  993. }
  994. }
  995. // elem-text
  996. .elem-text {
  997. .text-body {
  998. padding: 5px;
  999. line-height: 1.4;
  1000. span {
  1001. white-space: pre-wrap;
  1002. word-wrap: normal;
  1003. word-break: break-all;
  1004. &.cont-variate {
  1005. color: #a0a0a0;
  1006. margin: 0 2px;
  1007. }
  1008. }
  1009. }
  1010. }
  1011. // elem-barcode
  1012. .elem-barcode {
  1013. height: 100%;
  1014. border-color: transparent;
  1015. border-width: 1pt;
  1016. position: relative;
  1017. > img {
  1018. max-height: 100%;
  1019. max-width: 100%;
  1020. position: absolute;
  1021. top: 0;
  1022. bottom: 0;
  1023. left: 0;
  1024. right: 0;
  1025. margin: auto;
  1026. }
  1027. }
  1028. // elem-image
  1029. .elem-image {
  1030. height: 100%;
  1031. border-color: transparent;
  1032. border-width: 1pt;
  1033. position: relative;
  1034. > p {
  1035. position: absolute;
  1036. width: 100%;
  1037. height: 100%;
  1038. top: 0;
  1039. left: 0;
  1040. display: table;
  1041. text-align: center;
  1042. color: #b0b0b0;
  1043. font-size: 30pt;
  1044. i {
  1045. display: table-cell;
  1046. vertical-align: middle;
  1047. }
  1048. }
  1049. > img {
  1050. max-height: 100%;
  1051. max-width: 100%;
  1052. position: absolute;
  1053. top: 0;
  1054. bottom: 0;
  1055. left: 0;
  1056. right: 0;
  1057. margin: auto;
  1058. }
  1059. }
  1060. // elem-girds
  1061. .elem-grids {
  1062. > table {
  1063. table-layout: fixed;
  1064. border-spacing: 0;
  1065. border-collapse: collapse;
  1066. td {
  1067. border: 1px solid #000;
  1068. }
  1069. }
  1070. &-halving {
  1071. > table {
  1072. table-layout: auto;
  1073. width: 100%;
  1074. }
  1075. td > div {
  1076. padding-bottom: 100%;
  1077. }
  1078. }
  1079. }
  1080. .elem-pane {
  1081. height: 100%;
  1082. }
  1083. // elem-fill-question
  1084. .elem-fill-question {
  1085. white-space: normal;
  1086. // 客观题强调标记
  1087. &-first::before {
  1088. content: "";
  1089. position: absolute;
  1090. right: 0;
  1091. top: 0;
  1092. z-index: 99;
  1093. color: #fff;
  1094. padding: 6px 10px;
  1095. line-height: 1;
  1096. font-size: 18px;
  1097. border-bottom-left-radius: 10px;
  1098. }
  1099. &-first.elem-fill-question-simple {
  1100. &::before {
  1101. content: "单选";
  1102. background-color: mix(#fff, $--color-success, 20%);
  1103. }
  1104. }
  1105. &-first.elem-fill-question-multiply {
  1106. &::before {
  1107. content: "多选";
  1108. background-color: $--color-primary-light;
  1109. }
  1110. }
  1111. &-first.elem-fill-question-boolean {
  1112. &::before {
  1113. content: "判断";
  1114. background-color: mix(#fff, $--color-warning, 20%);
  1115. }
  1116. }
  1117. &-boolean {
  1118. .option-item {
  1119. &:nth-of-type(2) i {
  1120. background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAItJREFUOE/Vk9ERgCAMQ8M+GUInEyfTITKQV065KuDh8SWftHkNAQIGVxjU44cAkhHAAmCVFD8dwYktulnS3g2oiY2SAdZglmq34sS7pNn3JADJCcAGoGggaftWL2qFgzOc3OjEKbCau1sG3uo51TRN8c3BRX+E9SquAlwmU8t2EeLIf+h+B60hw4ADyTE7EWzzfYYAAAAASUVORK5CYII=);
  1121. background-size: 100% 100%;
  1122. width: 10px;
  1123. height: 10px;
  1124. margin-top: -1px;
  1125. }
  1126. &:nth-of-type(3) i {
  1127. background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAIVJREFUOE+tk9sNwCAIRa/7MES7WTerQ7BPGxolCpKmVT+Fe3gnTL40qUcHIKKNmXMEFTsA8TmqjwKK8SyG3YIiewQQjkKMGMysOlcCgJrFAykZdX9tdq6JNprphyttOIUA4sQCXw+YKmEg/tZEIrqapoVjbEe8bpEk8tsqj3zWHtOfy7wB41tXEXo/wKEAAAAASUVORK5CYII=);
  1128. background-size: 100% 100%;
  1129. width: 8px;
  1130. height: 8px;
  1131. }
  1132. }
  1133. }
  1134. .elem-body {
  1135. padding: 10px 5px;
  1136. font-size: 0;
  1137. }
  1138. .group-item {
  1139. font-family: "Times New Roman", Arial, sans-serif;
  1140. display: inline-block;
  1141. vertical-align: top;
  1142. font-size: 0;
  1143. // margin-bottom: 20px;
  1144. }
  1145. .question-item {
  1146. font-size: 0;
  1147. }
  1148. .option-item {
  1149. display: inline-block;
  1150. vertical-align: middle;
  1151. padding: 0;
  1152. width: 18px;
  1153. height: 10px;
  1154. text-align: center;
  1155. font-size: 12px;
  1156. line-height: 8px;
  1157. // border-rect
  1158. border: 1px solid #000;
  1159. color: #000;
  1160. box-sizing: border-box;
  1161. > i {
  1162. display: inline-block;
  1163. transform: scale(0.67, 0.67);
  1164. -webkit-transform: scale(0.67, 0.67);
  1165. }
  1166. &:first-child {
  1167. text-align: center;
  1168. border: none;
  1169. font-size: 12px;
  1170. line-height: 10px;
  1171. color: #000;
  1172. > i {
  1173. transform: scale(0.9, 0.9);
  1174. -webkit-transform: scale(0.9, 0.9);
  1175. }
  1176. }
  1177. &:last-child {
  1178. margin-right: 0 !important;
  1179. }
  1180. }
  1181. &-vertical {
  1182. .elem-body {
  1183. padding: 10px 20px;
  1184. }
  1185. .question-item {
  1186. display: inline-block;
  1187. vertical-align: top;
  1188. &:last-child {
  1189. margin-right: 0 !important;
  1190. }
  1191. }
  1192. .option-item {
  1193. display: block;
  1194. &:first-child {
  1195. padding: 0;
  1196. text-align: center;
  1197. }
  1198. &:last-child {
  1199. margin-bottom: 0 !important;
  1200. }
  1201. }
  1202. }
  1203. }
  1204. // elem-fill-area
  1205. .elem-fill-area {
  1206. .option-item {
  1207. display: inline-block;
  1208. vertical-align: middle;
  1209. width: 30px;
  1210. height: 16px;
  1211. border: 1px solid #000;
  1212. &:last-child {
  1213. margin-right: 0 !important;
  1214. }
  1215. }
  1216. &-vertical {
  1217. .option-item {
  1218. display: block;
  1219. &:last-child {
  1220. margin-bottom: 0 !important;
  1221. }
  1222. }
  1223. }
  1224. }
  1225. // elem-fill-line
  1226. .elem-fill-line {
  1227. white-space: normal;
  1228. .elem-body {
  1229. padding: 0 15px 0 10px;
  1230. font-size: 0;
  1231. }
  1232. .elem-fill-quesiton {
  1233. display: inline-block;
  1234. vertical-align: top;
  1235. position: relative;
  1236. padding: 0 1px;
  1237. font-size: 12px;
  1238. li {
  1239. &.elem-fill-line {
  1240. height: 40px;
  1241. position: relative;
  1242. margin: 0 10px 0 20px;
  1243. z-index: 8;
  1244. &::after {
  1245. content: "";
  1246. display: block;
  1247. position: absolute;
  1248. width: 100%;
  1249. border-bottom: 1px solid #000;
  1250. bottom: 8px;
  1251. }
  1252. }
  1253. &.elem-fill-no {
  1254. position: absolute;
  1255. top: 2px;
  1256. bottom: 2px;
  1257. left: 1px;
  1258. z-index: 9;
  1259. min-width: 20px;
  1260. text-align: left;
  1261. background-color: #fff;
  1262. border: none;
  1263. span {
  1264. display: block;
  1265. position: relative;
  1266. padding-bottom: 5px;
  1267. padding-right: 3px;
  1268. transform: translateY(-100%);
  1269. -webkit-transform: translateY(-100%);
  1270. }
  1271. }
  1272. &.elem-fill-comma {
  1273. position: absolute;
  1274. top: 0;
  1275. right: -10px;
  1276. z-index: 9;
  1277. transform: translateY(-100%);
  1278. -webkit-transform: translateY(-100%);
  1279. width: 10px;
  1280. padding-bottom: 4px;
  1281. background-color: #fff;
  1282. text-align: center;
  1283. border: none;
  1284. }
  1285. }
  1286. }
  1287. }
  1288. // elem-explain
  1289. .elem-explain {
  1290. .elem-title {
  1291. padding-bottom: 0;
  1292. }
  1293. .elem-body {
  1294. min-height: 60px;
  1295. position: relative;
  1296. }
  1297. .elem-explain-no {
  1298. position: absolute;
  1299. left: 20px;
  1300. top: 10px;
  1301. font-size: 12px;
  1302. z-index: 9;
  1303. }
  1304. .elem-explain-elements {
  1305. position: absolute;
  1306. width: 100%;
  1307. height: 100%;
  1308. top: 0;
  1309. left: 0;
  1310. z-index: 8;
  1311. }
  1312. .elem-explain-element {
  1313. .explain-element-body {
  1314. position: absolute;
  1315. }
  1316. }
  1317. }
  1318. // .elem-composition
  1319. .elem-composition {
  1320. .elem-title {
  1321. padding-bottom: 0;
  1322. }
  1323. .elem-body {
  1324. min-height: 60px;
  1325. position: relative;
  1326. }
  1327. &-elements {
  1328. position: absolute;
  1329. width: 100%;
  1330. height: 100%;
  1331. top: 0;
  1332. left: 0;
  1333. z-index: 8;
  1334. }
  1335. .elem-composition-element {
  1336. .composition-element-body {
  1337. position: absolute;
  1338. overflow: hidden;
  1339. }
  1340. }
  1341. }
  1342. // elem-fill-number
  1343. .elem-fill-number {
  1344. border: 1px solid #000;
  1345. .fill-number {
  1346. &-rect {
  1347. font-size: 0;
  1348. height: 27px;
  1349. border-bottom: 1px solid #000;
  1350. }
  1351. &-number {
  1352. display: inline-block;
  1353. vertical-align: top;
  1354. width: 7.692%;
  1355. height: 100%;
  1356. &:not(:last-child) {
  1357. border-right: 1px solid #000;
  1358. }
  1359. }
  1360. &-head {
  1361. height: 51px;
  1362. > h5 {
  1363. border-bottom: 1px solid #000;
  1364. line-height: 24px;
  1365. font-size: 16px;
  1366. font-weight: bold;
  1367. text-align: center;
  1368. }
  1369. }
  1370. &-body {
  1371. display: table;
  1372. width: 100%;
  1373. }
  1374. &-list {
  1375. display: table-cell;
  1376. width: 7.692%;
  1377. padding: 1px 0;
  1378. }
  1379. &-option {
  1380. margin: 8px auto;
  1381. width: 18px;
  1382. height: 10px;
  1383. font-size: 12px;
  1384. line-height: 8px;
  1385. text-align: center;
  1386. color: #000;
  1387. // border-rect
  1388. border: 1px solid #000;
  1389. font-family: "Times New Roman", Arial, sans-serif;
  1390. > i {
  1391. display: inline-block;
  1392. transform: scale(0.67, 0.67);
  1393. -webkit-transform: scale(0.67, 0.67);
  1394. }
  1395. }
  1396. }
  1397. }
  1398. // elem-fill-field
  1399. .elem-fill-field {
  1400. white-space: normal;
  1401. overflow: hidden;
  1402. }
  1403. .fill-field {
  1404. &-item {
  1405. display: inline-block;
  1406. padding: 0 10px;
  1407. width: 100%;
  1408. }
  1409. &-content {
  1410. height: 30px;
  1411. line-height: 26px;
  1412. overflow: hidden;
  1413. position: relative;
  1414. &::after {
  1415. content: "";
  1416. display: block;
  1417. position: absolute;
  1418. width: 100%;
  1419. border-bottom: 1px solid #000;
  1420. bottom: 2px;
  1421. left: 0;
  1422. z-index: 1;
  1423. }
  1424. > span {
  1425. z-index: 2;
  1426. display: block;
  1427. position: relative;
  1428. font-size: 14px;
  1429. &:first-child {
  1430. float: left;
  1431. background-color: #fff;
  1432. text-align: justify;
  1433. font-size: 0px;
  1434. & > i {
  1435. font-size: 14px;
  1436. }
  1437. &::after {
  1438. content: "";
  1439. display: inline-block;
  1440. width: 100%;
  1441. height: 0;
  1442. line-height: 0;
  1443. }
  1444. }
  1445. &:nth-of-type(2) {
  1446. float: left;
  1447. width: 20px;
  1448. background-color: #fff;
  1449. }
  1450. &:last-child {
  1451. margin-left: 80px;
  1452. height: 100%;
  1453. }
  1454. }
  1455. }
  1456. }
  1457. // elem-fill-pane
  1458. .elem-fill-pane {
  1459. font-size: 0;
  1460. white-space: normal;
  1461. overflow: hidden;
  1462. .fill-pane {
  1463. &-item {
  1464. display: inline-block;
  1465. vertical-align: top;
  1466. font-size: 14px;
  1467. }
  1468. &-cont {
  1469. border: 1px solid #000;
  1470. }
  1471. }
  1472. }
  1473. // elem-forbid-area
  1474. .elem-forbid-area {
  1475. height: 100%;
  1476. position: relative;
  1477. .text-body {
  1478. position: absolute;
  1479. width: 100%;
  1480. left: 0;
  1481. top: 50%;
  1482. transform: translateY(-50%);
  1483. -webkit-transform: translateY(-50%);
  1484. font-size: 30px;
  1485. text-align: center;
  1486. }
  1487. }
  1488. // elem-fill-table
  1489. .elem-fill-table {
  1490. .table {
  1491. width: 100%;
  1492. border-spacing: 0;
  1493. border-collapse: collapse;
  1494. text-align: left;
  1495. td {
  1496. padding: 0;
  1497. }
  1498. }
  1499. }
  1500. // elem-undertaking
  1501. .elem-undertaking {
  1502. position: absolute;
  1503. width: 60px;
  1504. top: 60px;
  1505. bottom: 60px;
  1506. right: 10px;
  1507. font-size: 12px;
  1508. line-height: 15px;
  1509. .para-text {
  1510. width: 15px;
  1511. text-align: center;
  1512. position: absolute;
  1513. top: 0;
  1514. span {
  1515. display: inline-block;
  1516. transform: rotate(90deg);
  1517. -webkit-transform: rotate(90deg);
  1518. }
  1519. em {
  1520. display: inline-block;
  1521. margin-left: 5px;
  1522. margin-bottom: 5px;
  1523. height: 10px;
  1524. line-height: 10px;
  1525. }
  1526. }
  1527. .para-title {
  1528. right: 0;
  1529. top: 50%;
  1530. transform: translateY(-50%);
  1531. -webkit-transform: translateY(-50%);
  1532. }
  1533. .para-cl {
  1534. right: 15px;
  1535. }
  1536. .para-body {
  1537. right: 30px;
  1538. height: 100%;
  1539. width: 30px;
  1540. > p {
  1541. display: block;
  1542. width: 15px;
  1543. height: 100%;
  1544. float: right;
  1545. &:first-child {
  1546. padding-top: 30px;
  1547. }
  1548. }
  1549. }
  1550. .para-std {
  1551. bottom: 130px;
  1552. top: auto;
  1553. left: 0;
  1554. }
  1555. }
  1556. // card-free-preview
  1557. .card-free-preview {
  1558. &:not(.card-print) {
  1559. padding: 10px 0;
  1560. background-color: #f0f0f0;
  1561. .page-box {
  1562. margin: 10px auto;
  1563. box-shadow: 0 0 4px #ddd;
  1564. }
  1565. }
  1566. .page-column-element {
  1567. .element-item {
  1568. position: absolute;
  1569. overflow: hidden;
  1570. &::before {
  1571. display: none;
  1572. }
  1573. }
  1574. }
  1575. }
  1576. @media print {
  1577. .card-preview {
  1578. padding: 0;
  1579. .page-box {
  1580. margin: 0 auto;
  1581. box-shadow: none;
  1582. page-break-after: always;
  1583. }
  1584. // 印刷模式:隐藏客观题强调标记
  1585. .elem-fill-question-first {
  1586. &::before {
  1587. display: none;
  1588. }
  1589. }
  1590. .elem-fill-question .option-item,
  1591. .card-print .elem-fill-number .fill-number-option,
  1592. .card-head-body .head-stdno .stdno-fill-option,
  1593. .page-number-rect-list li,
  1594. .card-head-body .head-dynamic-rect {
  1595. border-width: 0.5pt;
  1596. }
  1597. .elem-fill-question .option-item {
  1598. line-height: 9px;
  1599. }
  1600. }
  1601. }