Skip to content

Commit

Permalink
fix yarn issue, bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
skrsm committed Dec 9, 2022
1 parent 8202191 commit f2291f3
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 17 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<a href="https://www.gnu.org/licenses/gpl-3.0.html">
<img alt="License" src="https://img.shields.io/badge/License-GPL-blue.svg">
</a>
<a href="https://snyk.io/test/npm/cuttr/1.4.1">
<img src="https://snyk.io/test/npm/cuttr/1.4.1/badge.svg" alt="Known Vulnerabilities" data-canonical-src="https://snyk.io/test/npm/cuttr/1.3.1" style="max-width:100%;">
<a href="https://snyk.io/test/npm/cuttr/1.4.3">
<img src="https://snyk.io/test/npm/cuttr/1.4.3/badge.svg" alt="Known Vulnerabilities" data-canonical-src="https://snyk.io/test/npm/cuttr/1.4.3" style="max-width:100%;">
</a>
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=K9X3RW27WJHWE&source=url">
<img alt="License" src="https://img.shields.io/badge/donate-PayPal.me-ff69b4.svg">
Expand Down Expand Up @@ -56,23 +56,23 @@ Link directly to Cuttr files on [unpkg](https://unpkg.com/cuttr).
Link directly to Cuttr files on [cdnjs](https://cdnjs.com/libraries/cuttr).

``` html
<script src="https://cdnjs.cloudflare.com/ajax/libs/cuttr/1.4.1/cuttr.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/cuttr/1.4.3/cuttr.min.js"></script>
<!-- or -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/cuttr/1.4.1/cuttr.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/cuttr/1.4.3/cuttr.js"></script>

```

### Package managers
npm

```sh
npm install cuttr --save
npm install cuttr -D
```

yarn

```sh
yarn add cuttr
yarn add cuttr -D
```

bower
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "cuttr",
"description": "Cuttr is a javascript plugin that truncates multi-line string content with multiple truncation methods and custom ellipsis.",
"main": "dist/cuttr.js",
"version": "1.4.2",
"version": "1.4.3",
"authors": [
"DEVSK"
],
Expand Down
8 changes: 5 additions & 3 deletions dist/cuttr.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* Cuttr 1.4.1
* Cuttr 1.4.3
* https://github.com/d-e-v-s-k/cuttr-js
*
* @license GPLv3 for open source use only
Expand Down Expand Up @@ -131,6 +131,8 @@


function truncateIt(thisElement, str, length, ending) {
var _str$match;

var thisIndex = thisElement.dataset.cuttrIndex;
var truncateMethod = thisElement.dataset.cuttrMethod ? thisElement.dataset.cuttrMethod : self.options.truncate; // set defaults

Expand Down Expand Up @@ -181,7 +183,7 @@
// truncate full sentences

case 'sentences':
var sentences = str.match(/[^\.!\?]+[\.!\?]+/g); // check if content (string) is longer than truncation limit
var sentences = (_str$match = str.match(/[^\.!\?]+[\.!\?]+/g)) != null ? _str$match : []; // check if content (string) is longer than truncation limit

if (sentences.length > length) {
// set current contetn truncation true and return truncated string
Expand Down Expand Up @@ -490,7 +492,7 @@
return Cuttr;
});
/**
* jQuery adapter for Cuttr.js 1.4.0
* jQuery adapter for Cuttr.js 1.4.3
*/


Expand Down
4 changes: 2 additions & 2 deletions dist/cuttr.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/cuttr.min.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "cuttr",
"version": "1.4.2",
"version": "1.4.3",
"description": "Cuttr is a javascript / jQuery plugin that truncates multi-line string content with multiple truncation methods and custom ellipsis.",
"main": "dist/cuttr.js",
"unpkg": "dist/cuttr.min.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"preinstall": "npx npm-force-resolutions"
"preinstall": "([ ! -f package-lock.json ] && npm install --package-lock-only --ignore-scripts --no-audit); npx npm-force-resolutions"
},
"resolutions": {
"glob-parent": "^6.0.1",
Expand Down
4 changes: 2 additions & 2 deletions src/cuttr.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* Cuttr 1.4.2
* Cuttr 1.4.3
* https://github.com/d-e-v-s-k/cuttr-js
*
* @license GPLv3 for open source use only
Expand Down Expand Up @@ -596,7 +596,7 @@


/**
* jQuery adapter for Cuttr.js 1.4.2
* jQuery adapter for Cuttr.js 1.4.3
*/
if(window.jQuery && window.Cuttr){
(function ($, Cuttr) {
Expand Down

0 comments on commit f2291f3

Please sign in to comment.