flammarion 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. data/LICENSE +19 -0
  2. data/Readme.md +74 -0
  3. data/lib/flammarion.rb +155 -0
  4. data/lib/flammarion/pane.rb +12 -0
  5. data/lib/flammarion/server.rb +103 -0
  6. data/lib/flammarion/version.rb +3 -0
  7. data/lib/flammarion/writeable.rb +202 -0
  8. data/lib/html/Gemfile +19 -0
  9. data/lib/html/Gemfile.lock +151 -0
  10. data/lib/html/build/images/layers-2x.png +0 -0
  11. data/lib/html/build/images/layers.png +0 -0
  12. data/lib/html/build/images/marker-icon-2x.png +0 -0
  13. data/lib/html/build/images/marker-icon.png +0 -0
  14. data/lib/html/build/images/marker-shadow.png +0 -0
  15. data/lib/html/build/index.html +1 -0
  16. data/lib/html/build/javascripts/actions.js +415 -0
  17. data/lib/html/build/javascripts/all.js +7401 -0
  18. data/lib/html/build/javascripts/map.js +222 -0
  19. data/lib/html/build/javascripts/plot.js +288 -0
  20. data/lib/html/build/javascripts/querystring.js +39 -0
  21. data/lib/html/build/javascripts/status.js +37 -0
  22. data/lib/html/build/javascripts/vendor/ansi_up.js +327 -0
  23. data/lib/html/build/javascripts/vendor/highlight.pack.js +1 -0
  24. data/lib/html/build/javascripts/vendor/jquery.js +5 -0
  25. data/lib/html/build/javascripts/vendor/jquery.transit.min.js +1 -0
  26. data/lib/html/build/javascripts/vendor/l.control.geosearch.js +253 -0
  27. data/lib/html/build/javascripts/vendor/l.geosearch.provider.openstreetmap.js +297 -0
  28. data/lib/html/build/javascripts/vendor/leaflet.js +10 -0
  29. data/lib/html/build/javascripts/vendor/term.js +5974 -0
  30. data/lib/html/build/javascripts/websocket.js +166 -0
  31. data/lib/html/build/spectrum_test.html +12 -0
  32. data/lib/html/build/stylesheets/all.css +992 -0
  33. data/lib/html/build/stylesheets/buttons.css +179 -0
  34. data/lib/html/build/stylesheets/colors.css +0 -0
  35. data/lib/html/build/stylesheets/frontend.css +112 -0
  36. data/lib/html/build/stylesheets/leaflet.css +479 -0
  37. data/lib/html/build/stylesheets/map.css +0 -0
  38. data/lib/html/build/stylesheets/normalize.bak +375 -0
  39. data/lib/html/build/stylesheets/railscasts.css +185 -0
  40. data/lib/html/build/stylesheets/scrollbar.css +14 -0
  41. data/lib/html/build/stylesheets/table.css +21 -0
  42. data/lib/html/build/term_test.html +28 -0
  43. data/lib/html/config.rb +72 -0
  44. data/lib/html/source/images/layers-2x.png +0 -0
  45. data/lib/html/source/images/layers.png +0 -0
  46. data/lib/html/source/images/marker-icon-2x.png +0 -0
  47. data/lib/html/source/images/marker-icon.png +0 -0
  48. data/lib/html/source/images/marker-shadow.png +0 -0
  49. data/lib/html/source/index.html.slim +31 -0
  50. data/lib/html/source/javascripts/actions.coffee +192 -0
  51. data/lib/html/source/javascripts/all.js +3 -0
  52. data/lib/html/source/javascripts/map.coffee +43 -0
  53. data/lib/html/source/javascripts/plot.coffee +233 -0
  54. data/lib/html/source/javascripts/querystring.coffee +12 -0
  55. data/lib/html/source/javascripts/status.coffee +17 -0
  56. data/lib/html/source/javascripts/vendor/ansi_up.js +348 -0
  57. data/lib/html/source/javascripts/vendor/highlight.pack.js +1 -0
  58. data/lib/html/source/javascripts/vendor/jquery.js +4 -0
  59. data/lib/html/source/javascripts/vendor/jquery.transit.min.js +1 -0
  60. data/lib/html/source/javascripts/vendor/l.control.geosearch.js +242 -0
  61. data/lib/html/source/javascripts/vendor/l.geosearch.provider.openstreetmap.js +43 -0
  62. data/lib/html/source/javascripts/vendor/leaflet.js +9 -0
  63. data/lib/html/source/javascripts/vendor/term.js +5973 -0
  64. data/lib/html/source/javascripts/websocket.coffee +83 -0
  65. data/lib/html/source/layouts/layout.erb +0 -0
  66. data/lib/html/source/spectrum_test.html.slim +39 -0
  67. data/lib/html/source/stylesheets/all.css +2 -0
  68. data/lib/html/source/stylesheets/buttons.styl +115 -0
  69. data/lib/html/source/stylesheets/colors.styl +18 -0
  70. data/lib/html/source/stylesheets/frontend.styl +109 -0
  71. data/lib/html/source/stylesheets/leaflet.css +478 -0
  72. data/lib/html/source/stylesheets/map.styl +0 -0
  73. data/lib/html/source/stylesheets/normalize.bak +375 -0
  74. data/lib/html/source/stylesheets/railscasts.css +184 -0
  75. data/lib/html/source/stylesheets/scrollbar.styl +18 -0
  76. data/lib/html/source/stylesheets/table.styl +28 -0
  77. data/lib/html/source/term_test.html.slim +50 -0
  78. metadata +250 -0
@@ -0,0 +1,83 @@
1
+ #= require vendor/jquery.js
2
+ #= require status.coffee
3
+
4
+ class WSClient
5
+ constructor: ->
6
+ host = $qs.get("host") || "localhost"
7
+ console.log "Path: #{$qs.get("path")}, Port: #{$qs.get("port")}, Host: #{host}"
8
+ @ws = new WebSocket "ws://#{host}:#{$qs.get("port")}/#{$qs.get("path")}"
9
+ @actions["__parent"] = this
10
+ document.title = $qs.get("title") || "Flammarion Unconnected"
11
+ @ws.onopen = (msg) ->
12
+ $('body').addClass("connected")
13
+
14
+ @ws.onclose = (msg) ->
15
+ $('body').removeClass("connected")
16
+
17
+ @ws.onmessage = (msg) =>
18
+ console.log(msg)
19
+ data = $.parseJSON(msg.data)
20
+ if @actions[data.action]
21
+ @actions[data.action](data)
22
+ else
23
+ console.error("No such action: #{data.action}")
24
+
25
+ @status = new StatusDisplay(this, $('#status > .right'))
26
+
27
+ send: (data) ->
28
+ @ws.send JSON.stringify(data)
29
+
30
+ check_target: (data) ->
31
+ return data.target_element if data.target_element
32
+ data.target = "default" unless data.target
33
+ @actions.addpane {name:data.target} if $("#console-#{data.target}").size() is 0
34
+ @resize_panes
35
+ return $("#console-#{data.target}")
36
+
37
+ resize_panes: (data) ->
38
+ if data.target
39
+ target = @check_target(data)
40
+ else
41
+ target = $('#panes')
42
+
43
+ allPanes = target.find('> .pane')
44
+ height = (100.0 / allPanes.size()).toFixed(0) + "%"
45
+ if target.hasClass('horizontal')
46
+ orientation = 'horizontal'
47
+ else
48
+ orientation = 'vertical'
49
+
50
+ console.log target, allPanes.size(), 100.0 / allPanes.size(), height, orientation
51
+ for pane in allPanes
52
+ if orientation is 'horizontal'
53
+ $(pane).css "width", height
54
+ $(pane).css "height", '100%'
55
+ else
56
+ $(pane).css "height", height
57
+ $(pane).css "width", '100%'
58
+
59
+ escape: (text, input_options) ->
60
+ options =
61
+ raw: false
62
+ colorize: true
63
+ escape_html: true
64
+ $.extend(options, input_options)
65
+ return text if options.raw
66
+ text = "#{text}"
67
+ text = ansi_up.escape_for_html(text) if options.escape_html
68
+ text = ansi_up.ansi_to_html(text) if options.colorize
69
+ return text
70
+
71
+ add: (object, target, data) ->
72
+ if data.replace
73
+ target.html(object)
74
+ else
75
+ target.append(object)
76
+
77
+ actions:
78
+ __parent: null
79
+
80
+ $(document).ready ->
81
+ window.$ws = new WSClient
82
+
83
+ window.WSClient = WSClient
File without changes
@@ -0,0 +1,39 @@
1
+ ---
2
+ layout: false
3
+ ---
4
+
5
+ doctype html
6
+ html
7
+ head
8
+ meta[http-equiv="content-type" content="text/html; charset=UTF-8"]
9
+ meta charset="utf-8"
10
+ meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible"
11
+ meta[name="viewport" content="width=device-width, initial-scale=1.0"]
12
+ = stylesheet_link_tag("railscasts.css")
13
+ = stylesheet_link_tag("all")
14
+ = stylesheet_link_tag("scrollbar")
15
+ = javascript_include_tag("all")
16
+ javascript:
17
+ hljs.initHighlightingOnLoad();
18
+ coffee:
19
+ $(document).ready ->
20
+ $ws.actions.plot {
21
+ target: "default"
22
+ data: [-0.38,1.12,1.51,1.22,-0.41,0.12,0.71,-1.03,0.77,0.34,-0.09,-0.05,0.28,-0.04,1.62,0.42,0.19,0.66,-0.42,0.16,0.34,0.15,1.03,-0.56,1.79,-0.55,-0.53,0.25,0.69,2.57,0.71,0.8,1.09,0.56,0.16,-0.07,0.37,0.19,1.49,0.67,1.31,0.91,-0.33,-0.39,-0.13,0.13,1.37,1.82,0.7,1.06,1.02,0.68,0.03,1.48,0.07,0.78,1.6,-0.28,1.06,0.55,0.37,-0.31,0.36,0.34,0.51,-0.74,0.54,-0.54,0.93,1.29,-0.45,0.8,0.67,-0.51,0.14,1.43,1.81,0.35,0.72,0.59,1.44,0.46,0.62,0.49,0.65,0.71,0.14,2.96,-1.02,1.74,0.36,1.11,0.56,1.0,0.27,-0.5,0.52,0.12,1.49,0.73]
23
+ #data: [0, 1, 0, 2, 0, 1, 0]
24
+ id: 'ii3'
25
+ xscale: 0.5
26
+ }
27
+ body
28
+ #toolbar.hidden
29
+ a.tool-button[href="#"] Open
30
+ a.tool-button[href="#"] Save
31
+ #panes
32
+ pre#console-default.pane[style="height:100%"]
33
+ #dialog.hidden
34
+ pre#message Hi World
35
+ a.full-button[href="#"] Ok
36
+ #status
37
+ .left
38
+ .center
39
+ .right
@@ -0,0 +1,2 @@
1
+ //=require railscasts.css
2
+ //=require_tree
@@ -0,0 +1,115 @@
1
+ @import 'colors.styl'
2
+
3
+ buttony()
4
+ background-color lighten($bg-color, 0%)
5
+ color darken($fg-color, 0%)
6
+ font-family Monospace
7
+ border $normal-border
8
+ padding 1em
9
+ text-decoration none
10
+ display block
11
+ text-align center
12
+ margin-top 0.5em
13
+ margin-bottom 0.5em
14
+ user-select none
15
+ -webkit-user-select none
16
+
17
+ &:hover
18
+ background-color $highlight
19
+ &:active
20
+ background-color $active-highlight
21
+
22
+ .full-button
23
+ buttony()
24
+
25
+ .inline-text-input
26
+ buttony()
27
+ text-align left
28
+ box-sizing border-box
29
+ width 100%
30
+ &.unclicked
31
+ color darken($fg-color, 50%)
32
+ textarea&
33
+ height 25em
34
+
35
+ input::-webkit-input-placeholder
36
+ color darken($fg-color, 50%)
37
+
38
+ input:focus::-webkit-input-placeholder
39
+ opacity 0
40
+
41
+ .inline-checkbox
42
+ padding 0.2em
43
+ -webkit-user-select none
44
+ user-select none
45
+ & > span
46
+ vertical-align middle
47
+ & input[type=checkbox]
48
+ display: none
49
+ &:before
50
+ display inline-block
51
+ vertical-align middle
52
+ content " "
53
+ width 1em
54
+ height 1em
55
+ border $normal-border
56
+ margin-right 0.5em
57
+ &.checked:before
58
+ background-color activate($bg-color, 40%)
59
+ &:hover
60
+ background-color $highlight
61
+
62
+ #toolbar
63
+ background-color #000
64
+ margin 0px
65
+ font-family Monospace
66
+ height calc(2% + 15px)
67
+
68
+ .tool-button
69
+ float left
70
+ padding 0.5em
71
+ margin 0
72
+ text-decoration none
73
+ color $fg-color
74
+ border-right 1px solid
75
+ border-left 1px solid
76
+ margin-right 0.0em
77
+ &:hover
78
+ background-color #333
79
+
80
+ .button-box
81
+ position: absolute
82
+ top: 0.5em
83
+ right: 0.5em
84
+ margin-right: 0.5em
85
+ background-color: rgba(0, 0, 0, 0.5)
86
+ padding: 0.5em
87
+ z-index: 3
88
+
89
+ & .full-button, .inline-text-input, .inline-checkbox
90
+ float: left
91
+ margin: 0
92
+ padding: 0.2em
93
+ & .full-button:active, .inline-checkbox:active
94
+ margin-top: 0.1em
95
+ margin-bottom: -0.1em
96
+ & .inline-text-input
97
+ width auto
98
+ & .inline-checkbox
99
+ border $normal-border
100
+ &:before
101
+ border 1px solid darken($fg-color, 70%)
102
+ height 50%
103
+
104
+ .inline-button
105
+ buttony()
106
+ display inline
107
+
108
+ .floating-button
109
+ buttony()
110
+ float: left
111
+ margin: 0
112
+ padding: 0.2em
113
+ &:active
114
+ margin-top: 0.1em
115
+ margin-bottom: -0.1em
@@ -0,0 +1,18 @@
1
+ activate(color, ammount)
2
+ if dark(color)
3
+ lighten(color, ammount)
4
+ else
5
+ darken(color, ammount)
6
+
7
+ $bg-color = #120018
8
+
9
+ if dark($bg-color)
10
+ $fg-color = #eee
11
+ else
12
+ $fg-color = #333
13
+
14
+ $highlight = activate($bg-color, 10%)
15
+ $active-highlight = activate($bg-color, 20%)
16
+ $normal-border = 1px solid darken($fg-color, 30%)
17
+ $scrollbar-track-color = desaturate($active-highlight, 80%)
18
+ $scrollbar-thumb-color = desaturate(activate($scrollbar-track-color, 30%), 20%)
@@ -0,0 +1,109 @@
1
+ @charset "utf-8";
2
+ @import 'colors.styl'
3
+
4
+ body
5
+ background-color $bg-color
6
+ color $fg-color
7
+ padding 0px
8
+ margin 0px
9
+ height 100%
10
+ width 100%
11
+ overflow hidden
12
+
13
+ html
14
+ padding 0px
15
+ height 100%
16
+ width 100%
17
+ overflow hidden
18
+
19
+ a
20
+ text-decoration none
21
+
22
+ .hidden
23
+ display none
24
+
25
+ #status
26
+ background-color #000
27
+ margin 0px
28
+ padding 5px
29
+ padding-bottom 10px
30
+ font-family Monospace
31
+ height 2%
32
+ &:before
33
+ color #781111
34
+ content "Detached"
35
+ & > .left
36
+ float left
37
+ & > .right
38
+ float right
39
+ & > .center
40
+ // Not working right now
41
+ display none
42
+
43
+ .connected &
44
+ &:before
45
+ color #378137
46
+ content "Attached"
47
+ margin-right 2em
48
+ float left
49
+
50
+ .pane
51
+ margin 0px
52
+ overflow auto
53
+ padding 8px
54
+ width 100%
55
+ height 100%
56
+ box-sizing: border-box;
57
+ word-wrap: break-word;
58
+ position relative
59
+
60
+ .pane > .pane
61
+ margin -8px
62
+ margin-right -16px
63
+
64
+ #panes
65
+ height calc(98% - 15px)
66
+ width 100%
67
+ box-sizing: border-box
68
+
69
+ .horizontal .pane
70
+ height 100%
71
+ float left
72
+
73
+ .plot
74
+ width 100%
75
+ height 100%
76
+ border 1px solid #333
77
+ margin -1px
78
+ overflow none
79
+
80
+ #plot-mouseover
81
+ position absolute
82
+ background-color rgba(0, 0, 0, 0.5)
83
+ color $fg-color
84
+ pointer-events none
85
+ font-family Monospace
86
+
87
+ #plot-zoom-element
88
+ position absolute
89
+ background-color rgba(0, 3, 10, 0.75)
90
+ pointer-events none
91
+ border 1px solid #012
92
+
93
+ .hljs
94
+ background-color $bg-color
95
+
96
+ #dialog
97
+ position absolute
98
+ top 10%
99
+ left 10%
100
+ width 70%
101
+ height 70%
102
+ padding 1em
103
+ background-color darken($bg-color, 20%)
104
+ border $normal-border
105
+ & > #message
106
+ margin 0
107
+ height calc(100% - 3em)
108
+ & > .full-button
109
+ height 1em
@@ -0,0 +1,478 @@
1
+ /* required styles */
2
+
3
+ .leaflet-map-pane,
4
+ .leaflet-tile,
5
+ .leaflet-marker-icon,
6
+ .leaflet-marker-shadow,
7
+ .leaflet-tile-pane,
8
+ .leaflet-tile-container,
9
+ .leaflet-overlay-pane,
10
+ .leaflet-shadow-pane,
11
+ .leaflet-marker-pane,
12
+ .leaflet-popup-pane,
13
+ .leaflet-overlay-pane svg,
14
+ .leaflet-zoom-box,
15
+ .leaflet-image-layer,
16
+ .leaflet-layer {
17
+ position: absolute;
18
+ left: 0;
19
+ top: 0;
20
+ }
21
+ .leaflet-container {
22
+ overflow: hidden;
23
+ -ms-touch-action: none;
24
+ }
25
+ .leaflet-tile,
26
+ .leaflet-marker-icon,
27
+ .leaflet-marker-shadow {
28
+ -webkit-user-select: none;
29
+ -moz-user-select: none;
30
+ user-select: none;
31
+ -webkit-user-drag: none;
32
+ }
33
+ .leaflet-marker-icon,
34
+ .leaflet-marker-shadow {
35
+ display: block;
36
+ }
37
+ /* map is broken in FF if you have max-width: 100% on tiles */
38
+ .leaflet-container img {
39
+ max-width: none !important;
40
+ }
41
+ /* stupid Android 2 doesn't understand "max-width: none" properly */
42
+ .leaflet-container img.leaflet-image-layer {
43
+ max-width: 15000px !important;
44
+ }
45
+ .leaflet-tile {
46
+ filter: inherit;
47
+ visibility: hidden;
48
+ }
49
+ .leaflet-tile-loaded {
50
+ visibility: inherit;
51
+ }
52
+ .leaflet-zoom-box {
53
+ width: 0;
54
+ height: 0;
55
+ }
56
+ /* workaround for https://bugzilla.mozilla.org/show_bug.cgi?id=888319 */
57
+ .leaflet-overlay-pane svg {
58
+ -moz-user-select: none;
59
+ }
60
+
61
+ .leaflet-tile-pane { z-index: 2; }
62
+ .leaflet-objects-pane { z-index: 3; }
63
+ .leaflet-overlay-pane { z-index: 4; }
64
+ .leaflet-shadow-pane { z-index: 5; }
65
+ .leaflet-marker-pane { z-index: 6; }
66
+ .leaflet-popup-pane { z-index: 7; }
67
+
68
+ .leaflet-vml-shape {
69
+ width: 1px;
70
+ height: 1px;
71
+ }
72
+ .lvml {
73
+ behavior: url(#default#VML);
74
+ display: inline-block;
75
+ position: absolute;
76
+ }
77
+
78
+
79
+ /* control positioning */
80
+
81
+ .leaflet-control {
82
+ position: relative;
83
+ z-index: 7;
84
+ pointer-events: auto;
85
+ }
86
+ .leaflet-top,
87
+ .leaflet-bottom {
88
+ position: absolute;
89
+ z-index: 1000;
90
+ pointer-events: none;
91
+ }
92
+ .leaflet-top {
93
+ top: 0;
94
+ }
95
+ .leaflet-right {
96
+ right: 0;
97
+ }
98
+ .leaflet-bottom {
99
+ bottom: 0;
100
+ }
101
+ .leaflet-left {
102
+ left: 0;
103
+ }
104
+ .leaflet-control {
105
+ float: left;
106
+ clear: both;
107
+ }
108
+ .leaflet-right .leaflet-control {
109
+ float: right;
110
+ }
111
+ .leaflet-top .leaflet-control {
112
+ margin-top: 10px;
113
+ }
114
+ .leaflet-bottom .leaflet-control {
115
+ margin-bottom: 10px;
116
+ }
117
+ .leaflet-left .leaflet-control {
118
+ margin-left: 10px;
119
+ }
120
+ .leaflet-right .leaflet-control {
121
+ margin-right: 10px;
122
+ }
123
+
124
+
125
+ /* zoom and fade animations */
126
+
127
+ .leaflet-fade-anim .leaflet-tile,
128
+ .leaflet-fade-anim .leaflet-popup {
129
+ opacity: 0;
130
+ -webkit-transition: opacity 0.2s linear;
131
+ -moz-transition: opacity 0.2s linear;
132
+ -o-transition: opacity 0.2s linear;
133
+ transition: opacity 0.2s linear;
134
+ }
135
+ .leaflet-fade-anim .leaflet-tile-loaded,
136
+ .leaflet-fade-anim .leaflet-map-pane .leaflet-popup {
137
+ opacity: 1;
138
+ }
139
+
140
+ .leaflet-zoom-anim .leaflet-zoom-animated {
141
+ -webkit-transition: -webkit-transform 0.25s cubic-bezier(0,0,0.25,1);
142
+ -moz-transition: -moz-transform 0.25s cubic-bezier(0,0,0.25,1);
143
+ -o-transition: -o-transform 0.25s cubic-bezier(0,0,0.25,1);
144
+ transition: transform 0.25s cubic-bezier(0,0,0.25,1);
145
+ }
146
+ .leaflet-zoom-anim .leaflet-tile,
147
+ .leaflet-pan-anim .leaflet-tile,
148
+ .leaflet-touching .leaflet-zoom-animated {
149
+ -webkit-transition: none;
150
+ -moz-transition: none;
151
+ -o-transition: none;
152
+ transition: none;
153
+ }
154
+
155
+ .leaflet-zoom-anim .leaflet-zoom-hide {
156
+ visibility: hidden;
157
+ }
158
+
159
+
160
+ /* cursors */
161
+
162
+ .leaflet-clickable {
163
+ cursor: pointer;
164
+ }
165
+ .leaflet-container {
166
+ cursor: -webkit-grab;
167
+ cursor: -moz-grab;
168
+ }
169
+ .leaflet-popup-pane,
170
+ .leaflet-control {
171
+ cursor: auto;
172
+ }
173
+ .leaflet-dragging .leaflet-container,
174
+ .leaflet-dragging .leaflet-clickable {
175
+ cursor: move;
176
+ cursor: -webkit-grabbing;
177
+ cursor: -moz-grabbing;
178
+ }
179
+
180
+
181
+ /* visual tweaks */
182
+
183
+ .leaflet-container {
184
+ background: #ddd;
185
+ outline: 0;
186
+ }
187
+ .leaflet-container a {
188
+ color: #0078A8;
189
+ }
190
+ .leaflet-container a.leaflet-active {
191
+ outline: 2px solid orange;
192
+ }
193
+ .leaflet-zoom-box {
194
+ border: 2px dotted #38f;
195
+ background: rgba(255,255,255,0.5);
196
+ }
197
+
198
+
199
+ /* general typography */
200
+ .leaflet-container {
201
+ font: 12px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif;
202
+ }
203
+
204
+
205
+ /* general toolbar styles */
206
+
207
+ .leaflet-bar {
208
+ box-shadow: 0 1px 5px rgba(0,0,0,0.65);
209
+ border-radius: 4px;
210
+ }
211
+ .leaflet-bar a,
212
+ .leaflet-bar a:hover {
213
+ background-color: #fff;
214
+ border-bottom: 1px solid #ccc;
215
+ width: 26px;
216
+ height: 26px;
217
+ line-height: 26px;
218
+ display: block;
219
+ text-align: center;
220
+ text-decoration: none;
221
+ color: black;
222
+ }
223
+ .leaflet-bar a,
224
+ .leaflet-control-layers-toggle {
225
+ background-position: 50% 50%;
226
+ background-repeat: no-repeat;
227
+ display: block;
228
+ }
229
+ .leaflet-bar a:hover {
230
+ background-color: #f4f4f4;
231
+ }
232
+ .leaflet-bar a:first-child {
233
+ border-top-left-radius: 4px;
234
+ border-top-right-radius: 4px;
235
+ }
236
+ .leaflet-bar a:last-child {
237
+ border-bottom-left-radius: 4px;
238
+ border-bottom-right-radius: 4px;
239
+ border-bottom: none;
240
+ }
241
+ .leaflet-bar a.leaflet-disabled {
242
+ cursor: default;
243
+ background-color: #f4f4f4;
244
+ color: #bbb;
245
+ }
246
+
247
+ .leaflet-touch .leaflet-bar a {
248
+ width: 30px;
249
+ height: 30px;
250
+ line-height: 30px;
251
+ }
252
+
253
+
254
+ /* zoom control */
255
+
256
+ .leaflet-control-zoom-in,
257
+ .leaflet-control-zoom-out {
258
+ font: bold 18px 'Lucida Console', Monaco, monospace;
259
+ text-indent: 1px;
260
+ }
261
+ .leaflet-control-zoom-out {
262
+ font-size: 20px;
263
+ }
264
+
265
+ .leaflet-touch .leaflet-control-zoom-in {
266
+ font-size: 22px;
267
+ }
268
+ .leaflet-touch .leaflet-control-zoom-out {
269
+ font-size: 24px;
270
+ }
271
+
272
+
273
+ /* layers control */
274
+
275
+ .leaflet-control-layers {
276
+ box-shadow: 0 1px 5px rgba(0,0,0,0.4);
277
+ background: #fff;
278
+ border-radius: 5px;
279
+ }
280
+ .leaflet-control-layers-toggle {
281
+ background-image: url(images/layers.png);
282
+ width: 36px;
283
+ height: 36px;
284
+ }
285
+ .leaflet-retina .leaflet-control-layers-toggle {
286
+ background-image: url(images/layers-2x.png);
287
+ background-size: 26px 26px;
288
+ }
289
+ .leaflet-touch .leaflet-control-layers-toggle {
290
+ width: 44px;
291
+ height: 44px;
292
+ }
293
+ .leaflet-control-layers .leaflet-control-layers-list,
294
+ .leaflet-control-layers-expanded .leaflet-control-layers-toggle {
295
+ display: none;
296
+ }
297
+ .leaflet-control-layers-expanded .leaflet-control-layers-list {
298
+ display: block;
299
+ position: relative;
300
+ }
301
+ .leaflet-control-layers-expanded {
302
+ padding: 6px 10px 6px 6px;
303
+ color: #333;
304
+ background: #fff;
305
+ }
306
+ .leaflet-control-layers-selector {
307
+ margin-top: 2px;
308
+ position: relative;
309
+ top: 1px;
310
+ }
311
+ .leaflet-control-layers label {
312
+ display: block;
313
+ }
314
+ .leaflet-control-layers-separator {
315
+ height: 0;
316
+ border-top: 1px solid #ddd;
317
+ margin: 5px -10px 5px -6px;
318
+ }
319
+
320
+
321
+ /* attribution and scale controls */
322
+
323
+ .leaflet-container .leaflet-control-attribution {
324
+ background: #fff;
325
+ background: rgba(255, 255, 255, 0.7);
326
+ margin: 0;
327
+ }
328
+ .leaflet-control-attribution,
329
+ .leaflet-control-scale-line {
330
+ padding: 0 5px;
331
+ color: #333;
332
+ }
333
+ .leaflet-control-attribution a {
334
+ text-decoration: none;
335
+ }
336
+ .leaflet-control-attribution a:hover {
337
+ text-decoration: underline;
338
+ }
339
+ .leaflet-container .leaflet-control-attribution,
340
+ .leaflet-container .leaflet-control-scale {
341
+ font-size: 11px;
342
+ }
343
+ .leaflet-left .leaflet-control-scale {
344
+ margin-left: 5px;
345
+ }
346
+ .leaflet-bottom .leaflet-control-scale {
347
+ margin-bottom: 5px;
348
+ }
349
+ .leaflet-control-scale-line {
350
+ border: 2px solid #777;
351
+ border-top: none;
352
+ line-height: 1.1;
353
+ padding: 2px 5px 1px;
354
+ font-size: 11px;
355
+ white-space: nowrap;
356
+ overflow: hidden;
357
+ -moz-box-sizing: content-box;
358
+ box-sizing: content-box;
359
+
360
+ background: #fff;
361
+ background: rgba(255, 255, 255, 0.5);
362
+ }
363
+ .leaflet-control-scale-line:not(:first-child) {
364
+ border-top: 2px solid #777;
365
+ border-bottom: none;
366
+ margin-top: -2px;
367
+ }
368
+ .leaflet-control-scale-line:not(:first-child):not(:last-child) {
369
+ border-bottom: 2px solid #777;
370
+ }
371
+
372
+ .leaflet-touch .leaflet-control-attribution,
373
+ .leaflet-touch .leaflet-control-layers,
374
+ .leaflet-touch .leaflet-bar {
375
+ box-shadow: none;
376
+ }
377
+ .leaflet-touch .leaflet-control-layers,
378
+ .leaflet-touch .leaflet-bar {
379
+ border: 2px solid rgba(0,0,0,0.2);
380
+ background-clip: padding-box;
381
+ }
382
+
383
+
384
+ /* popup */
385
+
386
+ .leaflet-popup {
387
+ position: absolute;
388
+ text-align: center;
389
+ }
390
+ .leaflet-popup-content-wrapper {
391
+ padding: 1px;
392
+ text-align: left;
393
+ border-radius: 12px;
394
+ }
395
+ .leaflet-popup-content {
396
+ margin: 13px 19px;
397
+ line-height: 1.4;
398
+ }
399
+ .leaflet-popup-content p {
400
+ margin: 18px 0;
401
+ }
402
+ .leaflet-popup-tip-container {
403
+ margin: 0 auto;
404
+ width: 40px;
405
+ height: 20px;
406
+ position: relative;
407
+ overflow: hidden;
408
+ }
409
+ .leaflet-popup-tip {
410
+ width: 17px;
411
+ height: 17px;
412
+ padding: 1px;
413
+
414
+ margin: -10px auto 0;
415
+
416
+ -webkit-transform: rotate(45deg);
417
+ -moz-transform: rotate(45deg);
418
+ -ms-transform: rotate(45deg);
419
+ -o-transform: rotate(45deg);
420
+ transform: rotate(45deg);
421
+ }
422
+ .leaflet-popup-content-wrapper,
423
+ .leaflet-popup-tip {
424
+ background: white;
425
+
426
+ box-shadow: 0 3px 14px rgba(0,0,0,0.4);
427
+ }
428
+ .leaflet-container a.leaflet-popup-close-button {
429
+ position: absolute;
430
+ top: 0;
431
+ right: 0;
432
+ padding: 4px 4px 0 0;
433
+ text-align: center;
434
+ width: 18px;
435
+ height: 14px;
436
+ font: 16px/14px Tahoma, Verdana, sans-serif;
437
+ color: #c3c3c3;
438
+ text-decoration: none;
439
+ font-weight: bold;
440
+ background: transparent;
441
+ }
442
+ .leaflet-container a.leaflet-popup-close-button:hover {
443
+ color: #999;
444
+ }
445
+ .leaflet-popup-scrolled {
446
+ overflow: auto;
447
+ border-bottom: 1px solid #ddd;
448
+ border-top: 1px solid #ddd;
449
+ }
450
+
451
+ .leaflet-oldie .leaflet-popup-content-wrapper {
452
+ zoom: 1;
453
+ }
454
+ .leaflet-oldie .leaflet-popup-tip {
455
+ width: 24px;
456
+ margin: 0 auto;
457
+
458
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";
459
+ filter: progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678);
460
+ }
461
+ .leaflet-oldie .leaflet-popup-tip-container {
462
+ margin-top: -1px;
463
+ }
464
+
465
+ .leaflet-oldie .leaflet-control-zoom,
466
+ .leaflet-oldie .leaflet-control-layers,
467
+ .leaflet-oldie .leaflet-popup-content-wrapper,
468
+ .leaflet-oldie .leaflet-popup-tip {
469
+ border: 1px solid #999;
470
+ }
471
+
472
+
473
+ /* div icon */
474
+
475
+ .leaflet-div-icon {
476
+ background: #fff;
477
+ border: 1px solid #666;
478
+ }