5 The friendly panel is an all-purpose container for hiding content off-screen.
8 - Position at top, right, bottom, or left
9 - Anchor to grid block or window
10 - Define max width or height
11 - Transform into grid block depending on screen size
14 /// @Foundation.settings
16 $panel-size-horizontal: 300px !default;
17 $panel-size-vertical: 300px !default;
18 $panel-padding: 0 !default;
20 $panel-background: #fff !default;
21 $panel-shadow: 3px 0 10px rgba(black, 0.25) !default;
23 // DEPRECATED: these variables will be removed in a future version.
24 $panel-animation-speed: 0.25s !default;
42 $shadow: $panel-shadow
44 @if $size == default {
45 @if $position == left or $position == right {
46 $size: $panel-size-horizontal;
48 @if $position == top or $position == bottom {
49 $size: $panel-size-vertical;
56 @if $position == top {
61 @else if $position == right {
66 @else if $position == bottom {
71 @else if $position == left {
80 // Horizontal panels are always all the way tall and have a set width
81 @if $position == left or $position == right {
82 @if unit($size) == '%' {
87 @include breakpoint($size) {
92 // (For now) vertical panels don't change size
93 @if $position == top or $position == bottom {
100 $shadow-distance: get-shadow-value($shadow, x);
101 $shadow-size: get-shadow-value($shadow, size);
102 $shadow-color: get-shadow-value($shadow, color);
104 @if $position == left { box-shadow: $shadow-distance 0 $shadow-size $shadow-color; }
105 @else if $position == right { box-shadow: (-$shadow-distance) 0 $shadow-size $shadow-color; }
106 @else if $position == top { box-shadow: 0 $shadow-distance $shadow-size $shadow-color; }
107 @else if $position == bottom { box-shadow: 2px (-$shadow-distance) $shadow-size $shadow-color; }
112 $padding: $panel-padding,
113 $background: $panel-background
119 background: $background;
122 @include exports(panel) {
125 @include panel-style;
128 .panel-top { @include panel-layout(top); }
129 .panel-right { @include panel-layout(right); }
130 .panel-bottom { @include panel-layout(bottom); }
131 .panel-left { @include panel-layout(left); }
133 .panel-fixed { position: fixed; }