-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: add params for insert, pad, pad-left, pad-right
- Loading branch information
Showing
14 changed files
with
227 additions
and
133 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,3 +25,4 @@ | |
/package.json.ember-try | ||
|
||
.DS_Store | ||
pnpm-debug.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { insert } from 'voca'; | ||
import { helper } from "@ember/component/helper"; | ||
import { insert } from "voca"; | ||
|
||
export default helper(function vocaInsert(params/*, hash */ ) { | ||
return insert(params[0]); | ||
export default helper(function vocaInsert(params /*, hash */) { | ||
return insert(params[0], params[1], params[2]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { padLeft } from 'voca'; | ||
import { helper } from "@ember/component/helper"; | ||
import { padLeft } from "voca"; | ||
|
||
export default helper(function vocaPadLeft(params/*, hash */ ) { | ||
return padLeft(params[0]); | ||
export default helper(function vocaPadLeft(params /*, hash */) { | ||
return padLeft(params[0], params[1], params[2]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { padRight } from 'voca'; | ||
import { helper } from "@ember/component/helper"; | ||
import { padRight } from "voca"; | ||
|
||
export default helper(function vocaPadRight(params/*, hash */ ) { | ||
return padRight(params[0]); | ||
export default helper(function vocaPadRight(params /*, hash */) { | ||
return padRight(params[0], params[1], params[2]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { pad } from 'voca'; | ||
import { helper } from "@ember/component/helper"; | ||
import { pad } from "voca"; | ||
|
||
export default helper(function vocaPad(params/*, hash */ ) { | ||
return pad(params[0]); | ||
export default helper(function vocaPad(params /*, hash */) { | ||
return pad(params[0], params[1], params[2]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { search } from 'voca'; | ||
import { helper } from "@ember/component/helper"; | ||
import { search } from "voca"; | ||
|
||
export default helper(function vocaSearch(params/*, hash */ ) { | ||
return search(params[0]); | ||
export default helper(function vocaSearch(params /*, hash */) { | ||
return search(params[0], params[1]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,45 +1,45 @@ | ||
<h3>voca-camel-case:</h3> | ||
<p>Converts the argument to camel case.</p> | ||
<p> | ||
<h3>voca-camel-case:</h3> | ||
<p>Converts the argument to camel case.</p> | ||
<p> | ||
<pre class="language-handlebars"> | ||
<code class="language-handlebars"> | ||
\{{ voca-camel-case "bird flight"}} | ||
</code> | ||
</pre> | ||
|
||
</p> | ||
<p> | ||
<code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-camel-case "bird flight"}} | ||
</code> | ||
</p> | ||
</code> | ||
</p> | ||
|
||
<p> | ||
<p> | ||
<pre class="language-handlebars"> | ||
<code class="language-handlebars"> | ||
\{{ voca-camel-case "BirdFlight"}} | ||
</code> | ||
</pre> | ||
|
||
</p> | ||
<p> | ||
<code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-camel-case "BirdFlight"}} | ||
</code> | ||
</p> | ||
</code> | ||
</p> | ||
|
||
|
||
<p> | ||
<p> | ||
<pre class="language-handlebars"> | ||
<code class="language-handlebars"> | ||
\{{ voca-camel-case "-BIRD-FLIGHT-"}} | ||
</code> | ||
</pre> | ||
|
||
</p> | ||
<p> | ||
<code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-camel-case "-BIRD-FLIGHT-"}} | ||
</code> | ||
</p> | ||
</code> | ||
</p> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,29 @@ | ||
|
||
<h3>voca-capitalize:</h3> | ||
<p>Converts the first character of the argument to upper case. If the second argument is true, convert the rest of subject to lower case.</p> | ||
<p> | ||
<h3>voca-capitalize:</h3> | ||
<p>Converts the first character of the argument to upper case. If the second argument is true, convert the rest of subject to lower case.</p> | ||
<p> | ||
<pre class="language-handlebars"> | ||
<code class="language-handlebars"> | ||
\{{ voca-capitalize "apple"}} | ||
</code> | ||
</pre> | ||
|
||
</p> | ||
<p> | ||
<code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-capitalize "apple"}} | ||
</code> | ||
</p> | ||
</code> | ||
</p> | ||
|
||
<p> | ||
<p> | ||
<pre class="language-handlebars"> | ||
<code class="language-handlebars"> | ||
\{{ voca-capitalize "aPPle" true}} | ||
</code> | ||
</pre> | ||
|
||
</p> | ||
<p> | ||
<code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-capitalize "aPPle" true}} | ||
</code> | ||
</p> | ||
</code> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,22 @@ | ||
|
||
<h3>voca-insert:</h3> | ||
<p>Description for voca-insert goes here.</p> | ||
<p> | ||
<code> | ||
\{{ voca-insert "hello world"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-insert "hello world"}} | ||
</code> | ||
</p> | ||
<h3>voca-insert:</h3> | ||
<p>Inserts into subject a string toInsert at specified position</p> | ||
<p> | ||
<code> | ||
\{{ voca-insert "ct" "a" 1}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-insert "ct" "a" 1}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-insert "sunny" "day" 5}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-insert "sunny" "day" 5}} | ||
</code> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,32 @@ | ||
|
||
<h3>voca-latinise:</h3> | ||
<p>Description for voca-latinise goes here.</p> | ||
<p> | ||
<code> | ||
\{{ voca-latinise "hello world"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-latinise "hello world"}} | ||
</code> | ||
</p> | ||
<h3>voca-latinise:</h3> | ||
<p>Latinises the subject by removing diacritic characters.</p> | ||
<p> | ||
<code> | ||
\{{ voca-latinise "cafe\u0301"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-latinise "cafe\u0301"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-latinise "août décembre"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-latinise "août décembre"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-latinise "как прекрасен этот мир"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-latinise "как прекрасен этот мир"}} | ||
</code> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,32 @@ | ||
|
||
<h3>voca-pad-left:</h3> | ||
<p>Description for voca-pad-left goes here.</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-left "hello world"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-left "hello world"}} | ||
</code> | ||
</p> | ||
<h3>voca-pad-left:</h3> | ||
<p>Pads subject from left to a new length</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-left "dog" 5}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => '{{ voca-pad-left "dog" 5}}' | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-left "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-left "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-left "cat" 6 "-="}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-left "cat" 6 "-="}} | ||
</code> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,32 @@ | ||
|
||
<h3>voca-pad-right:</h3> | ||
<p>Description for voca-pad-right goes here.</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-right "hello world"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-right "hello world"}} | ||
</code> | ||
</p> | ||
<h3>voca-pad-right:</h3> | ||
<p>Pads subject from right to a new length.</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-right "dog" 5}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => '{{ voca-pad-right "dog" 5}}' | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-right "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-right "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad-right "cat" 6 "-="}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad-right "cat" 6 "-="}} | ||
</code> | ||
</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,32 @@ | ||
|
||
<h3>voca-pad:</h3> | ||
<p>Description for voca-pad goes here.</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad "hello world"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad "hello world"}} | ||
</code> | ||
</p> | ||
<h3>voca-pad:</h3> | ||
<p>Pads subject to a new length</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad "dog" 5}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => '{{ voca-pad "dog" 5}}' | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad "bird" 6 "-"}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
\{{ voca-pad "cat" 6 "-="}} | ||
</code> | ||
</p> | ||
<p> | ||
<code> | ||
// => {{ voca-pad "cat" 6 "-="}} | ||
</code> | ||
</p> |
Oops, something went wrong.