Browse Source

modififying popovers.

pull/214/head
connors 12 years ago
parent
commit
d2fa1feefc
  1. 22
      dist/ratchet.css
  2. 43
      docs/index.html
  3. 15
      lib/sass/bars.scss
  4. 9
      lib/sass/popovers.scss
  5. 2
      lib/sass/table-views.scss

22
dist/ratchet.css vendored

@ -380,6 +380,17 @@ strong {
color: #007aff; color: #007aff;
} }
.popover .bar-title {
padding-right: 15px;
padding-left: 15px;
border-bottom: 1px solid rgba(0, 0, 0, 0.15);
border-radius: 12px 12px 0 0;
box-shadow: none;
}
.popover .bar-title .title + [class*="button"]:last-child {
right: 15px;
}
.table-view { .table-view {
padding: 0; padding: 0;
margin: 0; margin: 0;
@ -470,8 +481,6 @@ strong {
margin-left: 0; margin-left: 0;
overflow: auto; overflow: auto;
background-color: #fff; background-color: #fff;
border: 1px solid rgba(0, 0, 0, 0.15);
border-radius: 3px;
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
} }
@ -896,10 +905,9 @@ input[type="button"] {
z-index: 20; z-index: 20;
display: none; display: none;
width: 280px; width: 280px;
padding: 5px;
margin-left: -140px; margin-left: -140px;
background-color: rgba(247, 247, 247, 0.98); background-color: rgba(247, 247, 247, 0.98);
border-radius: 6px; border-radius: 12px;
opacity: 0; opacity: 0;
box-shadow: 0 0 15px rgba(0, 0, 0, 0.1); box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
-webkit-transform: translate3d(0, -15px, 0); -webkit-transform: translate3d(0, -15px, 0);
@ -925,6 +933,7 @@ input[type="button"] {
display: box; display: box;
height: 34px; height: 34px;
margin-bottom: 5px; margin-bottom: 5px;
box-shadow: 0 0 1px rgba(0, 0, 0, 0.85);
} }
.popover-header .title { .popover-header .title {
position: absolute; position: absolute;
@ -967,6 +976,11 @@ input[type="button"] {
transform: translate3d(0, 0, 0); transform: translate3d(0, 0, 0);
} }
.popover-content {
overflow: hidden;
border-radius: 12px;
}
.backdrop { .backdrop {
position: fixed; position: fixed;
top: 0; top: 0;

43
docs/index.html

@ -949,8 +949,8 @@ document
<h3 class="component-title">Popovers</h3> <h3 class="component-title">Popovers</h3>
<div class="component-example"> <div class="component-example">
<div id="popover" class="popover"> <div id="popover" class="popover">
<header class="popover-header"> <header class="bar-title">
<a class="button"> <a class="button">
Left Left
</a> </a>
@ -959,18 +959,24 @@ document
Right Right
</a> </a>
</header> </header>
<ul class="table-view"> <div class="popover-content">
<li>Item1</li> <ul class="table-view">
<li>Item2</li> <li>Item1</li>
<li>Item3</li> <li>Item2</li>
<li>Item4</li> <li>Item3</li>
</ul> <li>Item4</li>
<li>Item5</li>
<li>Item6</li>
<li>Item7</li>
<li>Item8</li>
</ul>
</div>
</div> </div>
</div> </div>
<pre class="prettyprint"> <pre class="prettyprint">
&lt;div id=&quot;myPopover&quot; class=&quot;popover&quot;&gt; &lt;div id=&quot;myPopover&quot; class=&quot;popover&quot;&gt;
&lt;header class=&quot;popover-header&quot;&gt; &lt;header class=&quot;bar-title&quot;&gt;
&lt;a class=&quot;button&quot; href=&quot;#&quot;&gt; &lt;a class=&quot;button&quot; href=&quot;#&quot;&gt;
Left Left
&lt;/a&gt; &lt;/a&gt;
@ -979,12 +985,19 @@ document
Right Right
&lt;/a&gt; &lt;/a&gt;
&lt;/header&gt; &lt;/header&gt;
&lt;ul class=&quot;table-view&quot;&gt;
&lt;li&gt;Item1&lt;/li&gt; &lt;div class=&quot;popover-content&quot;&gt;
&lt;li&gt;Item2&lt;/li&gt; &lt;ul class=&quot;table-view&quot;&gt;
&lt;li&gt;Item3&lt;/li&gt; &lt;li&gt;Item1&lt;/li&gt;
&lt;li&gt;Item4&lt;/li&gt; &lt;li&gt;Item2&lt;/li&gt;
&lt;/ul&gt; &lt;li&gt;Item3&lt;/li&gt;
&lt;li&gt;Item4&lt;/li&gt;
&lt;li&gt;Item5&lt;/li&gt;
&lt;li&gt;Item6&lt;/li&gt;
&lt;li&gt;Item7&lt;/li&gt;
&lt;li&gt;Item8&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;/div&gt; &lt;/div&gt;
</pre> </pre>

15
lib/sass/bars.scss

@ -118,4 +118,19 @@
} }
.tab-item.active .tab-label { .tab-item.active .tab-label {
color: $primary-color; color: $primary-color;
}
// Nav bar in popovers
// --------------------------------------------------
.popover .bar-title {
padding-right: 15px;
padding-left: 15px;
border-bottom: 1px solid rgba(0,0,0,.15);
border-radius: 12px 12px 0 0;
box-shadow: none;
.title + [class*="button"]:last-child {
right: 15px;
}
} }

9
lib/sass/popovers.scss

@ -9,10 +9,9 @@
z-index: 20; z-index: 20;
display: none; display: none;
width: 280px; width: 280px;
padding: 5px;
margin-left: -140px; margin-left: -140px;
background-color: $chrome-color; background-color: $chrome-color;
border-radius: 6px; border-radius: 12px;
opacity: 0; opacity: 0;
box-shadow: 0 0 15px rgba(0, 0, 0, .1); box-shadow: 0 0 15px rgba(0, 0, 0, .1);
-webkit-transform: translate3d(0, -15px, 0); -webkit-transform: translate3d(0, -15px, 0);
@ -41,6 +40,7 @@
display: box; display: box;
height: 34px; height: 34px;
margin-bottom: 5px; margin-bottom: 5px;
box-shadow: 0 0 1px rgba(0,0,0,.85);
// Centered title for popover // Centered title for popover
.title { .title {
@ -96,6 +96,11 @@
} }
} }
.popover-content {
overflow: hidden;
border-radius: 12px;
}
// Backdrop (used as invisible touch escape) // Backdrop (used as invisible touch escape)
// -------------------------------------------------- // --------------------------------------------------

2
lib/sass/table-views.scss

@ -130,7 +130,5 @@
margin-left: 0; margin-left: 0;
overflow: auto; overflow: auto;
background-color: #fff; background-color: #fff;
border: 1px solid rgba(0, 0, 0, .15);
border-radius: 3px;
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
} }
Loading…
Cancel
Save