From 02de449a0474765a4796fa607e7e3922252f574f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B4=96=E9=B9=B0?= Date: Fri, 13 Nov 2015 11:33:48 +0800 Subject: release 0.1.0 --- assets/index.less | 22 ++++++++++++++++++ assets/index/Combobox.less | 4 ++++ assets/index/Header.less | 54 +++++++++++++++++++++++++++++++++++++++++++++ assets/index/Picker.less | 4 ++++ assets/index/Select.less | 50 +++++++++++++++++++++++++++++++++++++++++ assets/index/TimePanel.less | 16 ++++++++++++++ 6 files changed, 150 insertions(+) create mode 100644 assets/index.less create mode 100644 assets/index/Combobox.less create mode 100644 assets/index/Header.less create mode 100644 assets/index/Picker.less create mode 100644 assets/index/Select.less create mode 100644 assets/index/TimePanel.less (limited to 'assets') diff --git a/assets/index.less b/assets/index.less new file mode 100644 index 0000000..2ab247b --- /dev/null +++ b/assets/index.less @@ -0,0 +1,22 @@ +@prefixClass: rc-timepicker; + +.@{prefixClass} { + box-sizing: border-box; + * { + box-sizing: border-box; + } +} + +@font-face { + font-family: 'anticon'; + src: url('//at.alicdn.com/t/font_1434092639_4910953.eot'); + /* IE9*/ + src: url('//at.alicdn.com/t/font_1434092639_4910953.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ url('//at.alicdn.com/t/font_1434092639_4910953.woff') format('woff'), /* chrome、firefox */ url('//at.alicdn.com/t/font_1434092639_4910953.ttf') format('truetype'), /* chrome、firefox、opera、Safari, Android, iOS 4.2+*/ url('//at.alicdn.com/t/font_1434092639_4910953.svg#iconfont') format('svg'); + /* iOS 4.1- */ +} + +@import "./index/Picker"; +@import "./index/TimePanel"; +@import "./index/Header"; +@import "./index/Combobox"; +@import "./index/Select"; diff --git a/assets/index/Combobox.less b/assets/index/Combobox.less new file mode 100644 index 0000000..a796d0a --- /dev/null +++ b/assets/index/Combobox.less @@ -0,0 +1,4 @@ +.@{prefixClass} { + &-combobox { + } +} diff --git a/assets/index/Header.less b/assets/index/Header.less new file mode 100644 index 0000000..ac3d662 --- /dev/null +++ b/assets/index/Header.less @@ -0,0 +1,54 @@ +.@{prefixClass} { + &-input { + margin: 0; + padding: 0; + border: 0; + width: 100%; + cursor: auto; + line-height: 1.5; + outline: 0; + border: 1px solid transparent; + + &-wrap { + box-sizing: border-box; + position: relative; + padding: 6px; + border-bottom: 1px solid #e9e9e9; + } + + &-invalid { + border-color: red; + } + } + + &-clear-btn { + position: absolute; + right: 6px; + cursor: pointer; + overflow: hidden; + width: 20px; + height: 20px; + text-align: center; + line-height: 20px; + top: 6px; + margin: 0; + } + + &-clear-btn:after { + content: "x"; + font-size: 12px; + color: #aaa; + display: inline-block; + line-height: 1; + width: 20px; + transition: color 0.3s ease; + } + + &-clear-btn:hover:after { + color: #666; + } +} + +.narrow .@{prefixClass}-input-wrap { + max-width: 111px; +} diff --git a/assets/index/Picker.less b/assets/index/Picker.less new file mode 100644 index 0000000..769c4b7 --- /dev/null +++ b/assets/index/Picker.less @@ -0,0 +1,4 @@ +.@{prefixClass} { + &-picker { + } +} diff --git a/assets/index/Select.less b/assets/index/Select.less new file mode 100644 index 0000000..995d09e --- /dev/null +++ b/assets/index/Select.less @@ -0,0 +1,50 @@ +.@{prefixClass}-select { + float: left; + overflow-y:auto; + font-size: 12px; + border: 1px solid #e9e9e9; + border-width: 0 1px; + margin-left: -1px; + box-sizing: border-box; + width: 56px; + + &:first-child { + border-left: 0; + margin-left: 0; + } + + &:last-child { + border-right: 0; + } + + ul { + list-style: none; + box-sizing: border-box; + margin: 0; + padding: 0; + width: 100%; + max-height: 144px; + } + + li { + list-style: none; + box-sizing: border-box; + margin: 0; + padding: 0 0 0 16px; + width: 100%; + height: 24px; + line-height: 24px; + text-align: left; + cursor: pointer; + user-select: none; + + &.selected { + background: #edfaff; + color: #2db7f5; + } + + &:hover { + background: #edfaff; + } + } +} diff --git a/assets/index/TimePanel.less b/assets/index/TimePanel.less new file mode 100644 index 0000000..574605f --- /dev/null +++ b/assets/index/TimePanel.less @@ -0,0 +1,16 @@ +.@{prefixClass}-panel { + display: inline-block; + position: relative; + outline: none; + font-family: Arial, "Hiragino Sans GB", "Microsoft Yahei", "Microsoft Sans Serif", "WenQuanYi Micro Hei", sans-serif; + border: 1px solid #ccc; + list-style: none; + font-size: 12px; + text-align: left; + background-color: #fff; + border-radius: 3px; + box-shadow: 0 1px 5px #ccc; + background-clip: padding-box; + border: 1px solid #ccc; + line-height: 1.5; +} -- cgit v1.2.3