Skip to content

Commit 1d25447

Browse files
author
jfusco
committed
Patching to fix npmignore. Adding a copy command to webpack to copy over example/doc files and assets
1 parent 8972412 commit 1d25447

File tree

18 files changed

+1558
-54
lines changed

18 files changed

+1558
-54
lines changed

.npmignore

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
/.idea/
22
/__tests__/
33
/gulp/
4-
/src/
4+
/src/example/
5+
/src/component/js/
56
/coverage/
67
/docs/
7-
.editorconfig
8+
/webpack/
9+
/src/component/index.html
10+
/src/component/index.js
811
demo.gif
12+
.editorconfig
913
.babelrc
1014
.eslintignore
1115
.eslintrc

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ render(<Application />, document.getElementById('application'));
6969
* **[`maxTags`](#maxTags)**
7070
* **[`readOnly`](#readOnly)**
7171
* **[`removeTagIcon`](#removeTagIcon)**
72-
* **[`uniqueTags`](#allowDupes)**
72+
* **[`uniqueTags`](#uniqueTags)**
7373
* **[`id`](#id)**
7474

7575
<a name="initialTags"></a>
@@ -176,7 +176,7 @@ The `string` to be used for the ID of the component
176176
#### Installation
177177
Import the main SCSS file in to your application SCSS files
178178
```scss
179-
@import "node_modules/react-tagging-input/src/scss/react-tags";
179+
@import "node_modules/react-tagging-input/src/component/scss/styles.scss";
180180
```
181181

182182
There are a few variables set to `!default` that can be overriden. If you need to change it more just override the actual styles.
@@ -206,7 +206,7 @@ $tag-input-placeholder-color
206206

207207
If you don't care to override variables and just want to override actual styles you may choose to import the minified compiled version of the css instead
208208
```scss
209-
@import "node_modules/react-tagging-input/dist/react-tags.min.css";
209+
@import "node_modules/react-tagging-input/dist/react-tags.css";
210210
```
211211

212212
## Tests ##

docs/coverage/clover.xml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<coverage generated="1478448461685" clover="3.2.0">
3+
<project timestamp="1478448461685" name="All files">
4+
<metrics statements="52" coveredstatements="52" conditionals="71" coveredconditionals="52" methods="22" coveredmethods="22" elements="145" coveredelements="126" complexity="0" loc="52" ncloc="52" packages="1" files="2" classes="2">
5+
<file name="Tag.js" path="/Users/Rinzler/Projects/Personal/react-tagging-input/src/component/js/Tag.js">
6+
<metrics statements="8" coveredstatements="8" conditionals="7" coveredconditionals="6" methods="3" coveredmethods="3"/>
7+
<line num="3" count="2" type="stmt"/>
8+
<line num="5" count="2" type="stmt"/>
9+
<line num="6" count="95" type="stmt"/>
10+
<line num="7" count="2" type="stmt"/>
11+
<line num="9" count="2" type="stmt"/>
12+
<line num="12" count="95" type="stmt"/>
13+
<line num="18" count="95" type="stmt"/>
14+
<line num="28" count="2" type="stmt"/>
15+
</file>
16+
<file name="Tags.js" path="/Users/Rinzler/Projects/Personal/react-tagging-input/src/component/js/Tags.js">
17+
<metrics statements="44" coveredstatements="44" conditionals="64" coveredconditionals="46" methods="19" coveredmethods="19"/>
18+
<line num="1" count="5" type="stmt"/>
19+
<line num="6" count="23" type="stmt"/>
20+
<line num="8" count="1" type="stmt"/>
21+
<line num="50" count="23" type="stmt"/>
22+
<line num="52" count="1" type="stmt"/>
23+
<line num="55" count="10" type="stmt"/>
24+
<line num="56" count="2" type="stmt"/>
25+
<line num="61" count="9" type="stmt"/>
26+
<line num="63" count="9" type="stmt"/>
27+
<line num="64" count="1" type="stmt"/>
28+
<line num="67" count="8" type="stmt"/>
29+
<line num="70" count="8" type="stmt"/>
30+
<line num="71" count="2" type="stmt"/>
31+
<line num="74" count="8" type="stmt"/>
32+
<line num="75" count="2" type="stmt"/>
33+
<line num="83" count="4" type="stmt"/>
34+
<line num="84" count="4" type="stmt"/>
35+
<line num="86" count="4" type="stmt"/>
36+
<line num="89" count="4" type="stmt"/>
37+
<line num="90" count="2" type="stmt"/>
38+
<line num="93" count="4" type="stmt"/>
39+
<line num="94" count="2" type="stmt"/>
40+
<line num="100" count="14" type="stmt"/>
41+
<line num="102" count="4" type="stmt"/>
42+
<line num="104" count="4" type="stmt"/>
43+
<line num="105" count="3" type="stmt"/>
44+
<line num="108" count="4" type="stmt"/>
45+
<line num="111" count="10" type="stmt"/>
46+
<line num="113" count="10" type="stmt"/>
47+
<line num="114" count="10" type="stmt"/>
48+
<line num="115" count="3" type="stmt"/>
49+
<line num="118" count="10" type="stmt"/>
50+
<line num="121" count="10" type="stmt"/>
51+
<line num="126" count="14" type="stmt"/>
52+
<line num="128" count="14" type="stmt"/>
53+
<line num="129" count="5" type="stmt"/>
54+
<line num="132" count="14" type="stmt"/>
55+
<line num="138" count="49" type="stmt"/>
56+
<line num="140" count="49" type="stmt"/>
57+
<line num="141" count="102" type="stmt"/>
58+
<line num="149" count="49" type="stmt"/>
59+
<line num="161" count="49" type="stmt"/>
60+
<line num="163" count="49" type="stmt"/>
61+
<line num="172" count="1" type="stmt"/>
62+
</file>
63+
</metrics>
64+
</project>
65+
</coverage>

docs/coverage/coverage-final.json

Lines changed: 3 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<title>Code coverage report for Tag.js</title>
5+
<meta charset="utf-8" />
6+
<link rel="stylesheet" href="prettify.css" />
7+
<link rel="stylesheet" href="base.css" />
8+
<meta name="viewport" content="width=device-width, initial-scale=1">
9+
<style type='text/css'>
10+
.coverage-summary .sorter {
11+
background-image: url(sort-arrow-sprite.png);
12+
}
13+
</style>
14+
</head>
15+
<body>
16+
<div class='wrapper'>
17+
<div class='pad1'>
18+
<h1>
19+
<a href="index.html">All files</a> Tag.js
20+
</h1>
21+
<div class='clearfix'>
22+
<div class='fl pad1y space-right2'>
23+
<span class="strong">100% </span>
24+
<span class="quiet">Statements</span>
25+
<span class='fraction'>8/8</span>
26+
</div>
27+
<div class='fl pad1y space-right2'>
28+
<span class="strong">85.71% </span>
29+
<span class="quiet">Branches</span>
30+
<span class='fraction'>6/7</span>
31+
</div>
32+
<div class='fl pad1y space-right2'>
33+
<span class="strong">100% </span>
34+
<span class="quiet">Functions</span>
35+
<span class='fraction'>3/3</span>
36+
</div>
37+
<div class='fl pad1y space-right2'>
38+
<span class="strong">100% </span>
39+
<span class="quiet">Lines</span>
40+
<span class='fraction'>8/8</span>
41+
</div>
42+
</div>
43+
</div>
44+
<div class='status-line high'></div>
45+
<pre><table class="coverage">
46+
<tr><td class="line-count quiet">1
47+
2
48+
3
49+
4
50+
5
51+
6
52+
7
53+
8
54+
9
55+
10
56+
11
57+
12
58+
13
59+
14
60+
15
61+
16
62+
17
63+
18
64+
19
65+
20
66+
21
67+
22
68+
23
69+
24
70+
25
71+
26
72+
27
73+
28
74+
29
75+
30
76+
31
77+
32
78+
33
79+
34
80+
35
81+
36
82+
37
83+
38</td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
84+
<span class="cline-any cline-neutral">&nbsp;</span>
85+
<span class="cline-any cline-yes">2x</span>
86+
<span class="cline-any cline-neutral">&nbsp;</span>
87+
<span class="cline-any cline-yes">2x</span>
88+
<span class="cline-any cline-yes">95x</span>
89+
<span class="cline-any cline-yes">2x</span>
90+
<span class="cline-any cline-neutral">&nbsp;</span>
91+
<span class="cline-any cline-yes">2x</span>
92+
<span class="cline-any cline-neutral">&nbsp;</span>
93+
<span class="cline-any cline-neutral">&nbsp;</span>
94+
<span class="cline-any cline-yes">95x</span>
95+
<span class="cline-any cline-neutral">&nbsp;</span>
96+
<span class="cline-any cline-neutral">&nbsp;</span>
97+
<span class="cline-any cline-neutral">&nbsp;</span>
98+
<span class="cline-any cline-neutral">&nbsp;</span>
99+
<span class="cline-any cline-neutral">&nbsp;</span>
100+
<span class="cline-any cline-yes">95x</span>
101+
<span class="cline-any cline-neutral">&nbsp;</span>
102+
<span class="cline-any cline-neutral">&nbsp;</span>
103+
<span class="cline-any cline-neutral">&nbsp;</span>
104+
<span class="cline-any cline-neutral">&nbsp;</span>
105+
<span class="cline-any cline-neutral">&nbsp;</span>
106+
<span class="cline-any cline-neutral">&nbsp;</span>
107+
<span class="cline-any cline-neutral">&nbsp;</span>
108+
<span class="cline-any cline-neutral">&nbsp;</span>
109+
<span class="cline-any cline-neutral">&nbsp;</span>
110+
<span class="cline-any cline-yes">2x</span>
111+
<span class="cline-any cline-neutral">&nbsp;</span>
112+
<span class="cline-any cline-neutral">&nbsp;</span>
113+
<span class="cline-any cline-neutral">&nbsp;</span>
114+
<span class="cline-any cline-neutral">&nbsp;</span>
115+
<span class="cline-any cline-neutral">&nbsp;</span>
116+
<span class="cline-any cline-neutral">&nbsp;</span>
117+
<span class="cline-any cline-neutral">&nbsp;</span>
118+
<span class="cline-any cline-neutral">&nbsp;</span>
119+
<span class="cline-any cline-neutral">&nbsp;</span>
120+
<span class="cline-any cline-neutral">&nbsp;</span></td><td class="text"><pre class="prettyprint lang-js">'use strict';
121+
&nbsp;
122+
import React, { PropTypes } from 'react';<span class="branch-0 cbranch-no" title="branch not covered" ></span>
123+
&nbsp;
124+
const Tag = props =&gt; {
125+
const onRemoveClick = e =&gt; {
126+
e.preventDefault();
127+
&nbsp;
128+
props.onRemoveTag(e);
129+
};
130+
&nbsp;
131+
const removeIcon = !props.readOnly ? (
132+
&lt;a onClick={onRemoveClick}&gt;
133+
{props.removeTagIcon|| String.fromCharCode(215)}
134+
&lt;/a&gt;
135+
) : null;
136+
&nbsp;
137+
return (
138+
&lt;li&gt;
139+
{props.name}
140+
{removeIcon}
141+
&lt;/li&gt;
142+
);
143+
};
144+
&nbsp;
145+
export default Tag;
146+
&nbsp;
147+
Tag.propTypes = {
148+
name: PropTypes.string.isRequired,
149+
onRemoveTag: PropTypes.func,
150+
selectedTag: PropTypes.bool,
151+
readOnly: PropTypes.bool,
152+
removeTagIcon: PropTypes.oneOfType([
153+
PropTypes.string,
154+
PropTypes.element
155+
])
156+
};
157+
&nbsp;</pre></td></tr>
158+
</table></pre>
159+
<div class='push'></div><!-- for sticky footer -->
160+
</div><!-- /wrapper -->
161+
<div class='footer quiet pad2 space-top1 center small'>
162+
Code coverage
163+
generated by <a href="http://istanbul-js.org/" target="_blank">istanbul</a> at Sun Nov 06 2016 11:07:41 GMT-0500 (EST)
164+
</div>
165+
</div>
166+
<script src="prettify.js"></script>
167+
<script>
168+
window.onload = function () {
169+
if (typeof prettyPrint === 'function') {
170+
prettyPrint();
171+
}
172+
};
173+
</script>
174+
<script src="sorter.js"></script>
175+
</body>
176+
</html>

0 commit comments

Comments
 (0)