search-bar.css 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. .lin-search{
  2. background-color: #fff;
  3. padding: 8px 10px;
  4. }
  5. .lin-search .search-input{
  6. width:100%;
  7. background-color: #f2f2f2;
  8. border-radius: 5px;
  9. color: #ccc;
  10. height:28px;
  11. line-height: 28px;
  12. }
  13. .searchbar {
  14. height: 44px;
  15. box-sizing: border-box;
  16. padding: 0 8px;
  17. overflow: hidden;
  18. position: relative;
  19. display: -webkit-box;
  20. display: -ms-flexbox;
  21. display: -webkit-flex;
  22. display: flex;
  23. -webkit-box-align: center;
  24. -ms-flex-align: center;
  25. -webkit-align-items: center;
  26. align-items: center;
  27. background-color: #17b3ec;
  28. }
  29. html.pixel-ratio-2 .searchbar:after {
  30. -webkit-transform: scaleY(.5);
  31. transform: scaleY(.5)
  32. }
  33. html.pixel-ratio-3 .searchbar:after {
  34. -webkit-transform: scaleY(.33);
  35. transform: scaleY(.33)
  36. }
  37. .searchbar .searchbar-input {
  38. width: 100%;
  39. height: 28px;
  40. position: relative;
  41. border-radius: 5px;
  42. -webkit-flex-shrink: 1;
  43. -ms-flex: 0 1 auto;
  44. flex-shrink: 1;
  45. }
  46. .searchbar input[type=search] {
  47. box-sizing: border-box;
  48. width: 100%;
  49. height: 100%;
  50. display: block;
  51. border: none;
  52. -webkit-appearance: none;
  53. -moz-appearance: none;
  54. -ms-appearance: none;
  55. appearance: none;
  56. border-radius: 5px;
  57. font-family: inherit;
  58. color: #000;
  59. font-size: 14px;
  60. font-weight: 400;
  61. padding: 0 28px;
  62. background-repeat: no-repeat;
  63. background-position: 8px center;
  64. background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACMAAAAjCAYAAAAe2bNZAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyFpVFh0W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eA9N5LBPhhLqWwiWiq9je1hZjqMVxmip+5mIpW5hkGrvEthIjcV59PkkzTT7GSgNXAKMtxZimP1V913kfCoWq+Wnld1uLMc3VKPCSIvqBdzKu/gowAICpvmijfvwCAAAAAElFTkSuQmCC");
  65. -webkit-background-size: 13px 13px;
  66. background-size: 13px 13px;
  67. background-color: #fff;
  68. }
  69. .searchbar input[type=search]::-webkit-input-placeholder {
  70. color: #ccc;
  71. opacity: 1
  72. }
  73. .searchbar input[type=search]::-webkit-search-cancel-button {
  74. -webkit-appearance: none
  75. }
  76. .searchbar .searchbar-clear {
  77. position: absolute;
  78. width: 28px;
  79. height: 28px;
  80. right: 0;
  81. top: 0;
  82. opacity: 0;
  83. pointer-events: none;
  84. background-position: center;
  85. background-repeat: no-repeat;
  86. background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2028%2028'%3E%3Ccircle%20cx%3D'14'%20cy%3D'14'%20r%3D'14'%20fill%3D'%238e8e93'%2F%3E%3Cline%20stroke%3D'%23ffffff'%20stroke-width%3D'2'%20stroke-miterlimit%3D'10'%20x1%3D'8'%20y1%3D'8'%20x2%3D'20'%20y2%3D'20'%2F%3E%3Cline%20fill%3D'none'%20stroke%3D'%23ffffff'%20stroke-width%3D'2'%20stroke-miterlimit%3D'10'%20x1%3D'20'%20y1%3D'8'%20x2%3D'8'%20y2%3D'20'%2F%3E%3C%2Fsvg%3E");
  87. -webkit-background-size: 14px 14px;
  88. background-size: 14px 14px;
  89. -webkit-transition-duration: .3s;
  90. transition-duration: .3s;
  91. cursor: pointer
  92. }
  93. .searchbar .searchbar-clear.active{
  94. opacity: .3;
  95. pointer-events: auto;
  96. display: block;
  97. -webkit-transition-duration: 0s;
  98. transition-duration: 0s
  99. }
  100. .searchbar .searchbar-cancel {
  101. -webkit-transition-duration: .3s;
  102. transition-duration: .3s;
  103. -webkit-transform: translate3d(0,0,0);
  104. transform: translate3d(0,0,0);
  105. font-size: 16px;
  106. cursor: pointer;
  107. opacity: 0;
  108. -webkit-flex-shrink: 0;
  109. -ms-flex: 0 0 auto;
  110. flex-shrink: 0;
  111. margin-left: 0;
  112. pointer-events: none;
  113. display: none;
  114. color: #fff;
  115. }
  116. .searchbar.searchbar-active .searchbar-cancel {
  117. margin-left: 8px;
  118. opacity: 1;
  119. pointer-events: auto;
  120. display: block;
  121. }
  122. .searchbar.searchbar-active .searchbar-cancel.active-state,html:not(.watch-active-state) .searchbar.searchbar-active .searchbar-cancel:active {
  123. opacity: .3;
  124. -webkit-transition-duration: 0s;
  125. transition-duration: 0s
  126. }