current_template 0.1.1 → 0.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6237dd599f6f63ef8a0fb45feb9afeff6ffaefc3
4
- data.tar.gz: ffce91008633e6163b439cd3904dac7ed472a34c
3
+ metadata.gz: 3b06c9145a691472a58489402a0369da6c68180f
4
+ data.tar.gz: 43e2edef1d5e8a7c35d810e96843ed8f71c2689d
5
5
  SHA512:
6
- metadata.gz: 87e8fe361d320dc743f74d47ec0a8f47475bb4c84b352335147f77b5fd6b96bc2f6b8fbc7744622cef35e2cf88a5675ecf5ba853889e9bab7c799c2cc25ff143
7
- data.tar.gz: e872a061de375bffe138bea356777aeba50fd6f0cada907ab748258cee0497cf086d4592387fa1514262bdcdd280bb7b118545cb07fa8d556aa4f791c49a1890
6
+ metadata.gz: e8d43033e71b8304d3b6d5071a4f744f18f1e10b9d96c4c2d58a6dfbb70e353b345a02e6d85343244090b13aa343984a2b357174b85eb5f619288245fefbab85
7
+ data.tar.gz: 76c7e87c12cd1ebb55424316020184289f41002a432f02886dd2bfb42c0de15c8b63541807e724d8b107ecb3a4d589d362fcf063b21b537560bb607e65422dc8
data/README.md CHANGED
@@ -2,15 +2,17 @@
2
2
  Display name of the current template file, including partial template.
3
3
 
4
4
  ## Demo
5
- ![demo](https://github.com/shihokambara/current_template/blob/master/screenshot.jpg)
5
+ ![demo](https://github.com/shihokambara/current_template/blob/master/demo.gif)
6
6
 
7
7
  ## Feature
8
8
 
9
- This gem inspects log/development.log and gets partial name from it!
10
- It doesn't override any method!
9
+ This gem inspects `log/development.log` and gets partial name from it!
10
+ It doesn't override any method.
11
+
12
+ This gem also supports haml and slim.
11
13
 
12
14
  ```ruby
13
- <%= "#{`tail log/development.log`}".scan(/\s[a-z]+\/\S+/) %>
15
+ Template: <%= "#{`tail log/development.log`}".scan(/\s[a-z]+\/\S+[erb|haml|slim]\s/) %> # extract data from log file
14
16
  ```
15
17
 
16
18
  ## Installation
@@ -1,8 +1,8 @@
1
- <div class='current_template-container' >
1
+ <div class='current_template-container' style='-webkit-user-drag: element;' >
2
+ <span id="current_template-close" onclick="parentNode.remove()"></span>
2
3
  <small>CurrentTemplateViewer</small>
3
4
  <p class='current_template-inner'>
4
5
  Template: <%= "#{`tail log/development.log`}".scan(/\s[a-z]+\/\S+[erb|haml|slim]\s/) %>
5
-
6
6
  </p>
7
7
  </div>
8
8
  <style>
@@ -17,10 +17,24 @@
17
17
  padding: 10px 40px;
18
18
  border-radius: 5px;
19
19
  z-index: 999999;
20
- font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
20
+ font-family: "Helvetica Neue",Helvetica,Arial,sans-serif !important;
21
21
  font-weight: 200;
22
22
  }
23
23
  .current_template-inner{
24
24
  margin-top: 20px;
25
25
  }
26
+ #current_template-close{
27
+ color: #fff;
28
+ position: absolute;
29
+ right: 5px;
30
+ top: 0px;
31
+ padding: 4px 10px;
32
+ cursor: pointer;
33
+ }
34
+ #current_template-close:hover{
35
+ color: #fff;
36
+ }
37
+ #current_template-close:after {
38
+ content: '×'; /* UTF-8 symbol */
39
+ }
26
40
  </style>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: current_template
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - shiho kambara