test.blade.php 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title>简单的模态框(Modal)</title>
  6. <style>
  7. .modal:before {
  8. content: "";
  9. display: none;
  10. background: rgba(0, 0, 0, 0.6);
  11. position: fixed;
  12. top: 0;
  13. left: 0;
  14. right: 0;
  15. bottom: 0;
  16. z-index: 10;
  17. }
  18. .modal:target:before {
  19. display: block;
  20. }
  21. .modal:target .modal-dialog {
  22. -webkit-transform: translate(0, 0);
  23. -ms-transform: translate(0, 0);
  24. transform: translate(0, 0);
  25. top: 20%;
  26. }
  27. .modal-dialog {
  28. background: #fefefe;
  29. border: #333 solid 1px;
  30. border-radius: 5px;
  31. margin-left: -120px;
  32. position: fixed;
  33. left: 35%;
  34. z-index: 11;
  35. width: 800px;
  36. -webkit-transform: translate(0, -500%);
  37. -ms-transform: translate(0, -500%);
  38. transform: translate(0, -500%);
  39. -webkit-transition: -webkit-transform 0.3s ease-out;
  40. -moz-transition: -moz-transform 0.3s ease-out;
  41. -o-transition: -o-transform 0.3s ease-out;
  42. transition: transform 0.3s ease-out;
  43. }
  44. .modal-body {
  45. padding: 10px 20px;
  46. }
  47. .modal-header {
  48. border-bottom: #eee solid 1px;
  49. }
  50. .modal-header h2 {
  51. font-size: 20px;
  52. margin-left: 30px;
  53. }
  54. .box-shadow-dark{
  55. box-shadow: 0 0 10px 5px rgba(0,0,0,0.9);
  56. z-index:100;
  57. position:relative;
  58. }
  59. .modal-body-div{
  60. width: 30%;
  61. display: inline-block;
  62. }
  63. .modal-body-item{
  64. margin: 10px;
  65. border: 3px solid red;
  66. border-radius: 5px;
  67. height:100px;
  68. text-align: center;
  69. display: flex;
  70. align-items: center;
  71. justify-content: center;
  72. flex-direction: column
  73. }
  74. .modal-body-item-text{
  75. margin-left:10%;
  76. width: 80%;
  77. }
  78. .modal-footer {
  79. padding: 10px 20px;
  80. }
  81. .modal-footer {
  82. border-top: #eee solid 1px;
  83. text-align: right;
  84. }
  85. .btn {
  86. background: #428bca;
  87. border: #357ebd solid 1px;
  88. border-radius: 3px;
  89. color: #fff;
  90. display: inline-block;
  91. font-size: 14px;
  92. padding: 8px 15px;
  93. text-decoration: none;
  94. text-align: center;
  95. min-width: 60px;
  96. position: relative;
  97. transition: color .1s ease;
  98. }
  99. .btn:hover {
  100. background: #357ebd;
  101. }
  102. </style>
  103. </head>
  104. <body>
  105. <a href="#modal-one">111</a>
  106. <div class="modal" id="modal-one" aria-hidden="true">
  107. <div class="modal-dialog">
  108. <div class="modal-header">
  109. <h2>选择仓库</h2>
  110. </div>
  111. <div class="modal-body">
  112. <div class="modal-body-div" data-id="1">
  113. <div class="box-shadow-dark modal-body-item"><div class="modal-body-item-text">测试喜喜喜喜喜喜喜喜喜喜顶顶顶顶顶顶顶顶顶顶顶</div></div>
  114. </div>
  115. <div class="modal-body-div">
  116. <div class="box-shadow-dark modal-body-item"><div class="modal-body-item-text">测试喜喜喜喜喜喜喜喜喜喜顶顶顶顶顶顶顶顶顶顶顶</div></div>
  117. </div>
  118. <div class="modal-body-div">
  119. <div class="box-shadow-dark modal-body-item"><div class="modal-body-item-text">测试喜喜喜喜喜喜喜喜喜喜顶顶顶顶顶顶顶顶顶顶顶</div></div>
  120. </div>
  121. <div class="modal-body-div">
  122. <div class="box-shadow-dark modal-body-item"><div class="modal-body-item-text">测试喜喜喜喜喜喜喜喜喜喜顶顶顶顶顶顶顶顶顶顶顶</div></div>
  123. </div>
  124. </div>
  125. <div class="modal-footer">
  126. <a href="#" class="btn" onclick="test()">确 定</a>
  127. </div>
  128. </div>
  129. </div>
  130. <script type="text/javascript">
  131. function test() {
  132. }
  133. </script>
  134. </body>
  135. </html>