Skip to content

Commit

Permalink
New version 3.0.1. Read more http://xdsoft.net/jodit/#3.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
xdan committed Aug 1, 2017
1 parent a4bde51 commit 6f6da66
Show file tree
Hide file tree
Showing 36 changed files with 91 additions and 150 deletions.
35 changes: 29 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,38 @@ An excellent WYSIWYG editor written in pure TypeScript without the use of additi
## For contributors:
```$xslt
yarn install
npm install
```

Run webpack Hot Reload server:
```$xslt
yarn start
npm start
```

Build min files:
```$xslt
yarn run build
npm run build
```

For check tests, open in browser:
Run tests:
```$xslt
karma start --browsers ChromeHeadless,IE,Firefox karma.conf.js
```
or
```$xslt
npm test
```
or
```$xslt
yarn test
```

For checking tests in browser, open URL:
```$xslt
http://localhost:2000/test/test.html
```

For testing FileBrowser and Uploader need install [PHP Connector](https://github.com/xdan/jodit-connectors)
For testing FileBrowser and Uploader modules, need install [PHP Connector](https://github.com/xdan/jodit-connectors)
```
composer create-project jodit/connector
```
Expand Down Expand Up @@ -59,6 +72,13 @@ After this, you can init Jodit plugin
new Jodit('#editor');
```

With jQuery
```javascript
$('textarea').each(function (elm) {
new Jodit(elm);
});
```

## Browser Support
______________________
* Internet Explorer 9
Expand All @@ -69,6 +89,9 @@ ______________________


## Changelog
### 3.0.2
* Now `options`.`language` by default equal `auto`. It means that after init Jodit, it try define page language (`<html lang="de">`), if it is impossible, editor define language by browser.language.
* Added `options`.`debugLanguage`=`false` if true, editro ignore `options`.`language` and `editor.i18n(key)` return `'{key}'`
### 3.0.1
Restore inline toolbar for Images and Tables
* Restore inline toolbar for Images and Tables

4 changes: 2 additions & 2 deletions dist/jodit.css

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

6 changes: 3 additions & 3 deletions dist/jodit.js

Large diffs are not rendered by default.

9 changes: 4 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"name": "jodit",
"version": "3.0.1",
"version": "3.0.2",
"description": "Jodit is awesome and usefully wysiwyg editor with filebrowser",
"main": "index.js",
"scripts": {
"newversion": "npm version patch --no-git-tag-version && npm run build && git add --all && git commit -m \"New version %npm_package_version%. Read more http://xdsoft.net/jodit/#%npm_package_version% \" && git tag %npm_package_version% && git push --tags gitlab HEAD:master",
"gitlab": "git add --all && git commit -m 'Commit' && git push -u origin master",
"start": "node server.js",
"build": "rm -f dist/* && cross-env NODE_ENV=production webpack --progress",
"test": "karma start --browsers ChromeHeadless,IE,Firefox karma.conf.js",
"test:static": "mocha-phantomjs test/test.html "
"test": "karma start --browsers ChromeHeadless,IE,Firefox karma.conf.js"
},
"repository": {
"type": "git",
Expand All @@ -25,7 +25,7 @@
"bugs": {
"url": "https://github.com/xdan/jodit/issues"
},
"homepage": "https://github.com/xdan/jodit#readme",
"homepage": "http://xdsoft.net/jodit/",
"devDependencies": {
"@types/node": "^7.0.39",
"autoprefixer": "^6.7.7",
Expand All @@ -38,7 +38,6 @@
"express": "^4.15.3",
"extract-text-webpack-plugin": "^2.1.2",
"file-loader": "^0.10.1",
"jquery": "^3.1.1",
"karma": "^1.7.0",
"karma-chai": "^0.1.0",
"karma-chrome-launcher": "^2.2.0",
Expand Down
7 changes: 6 additions & 1 deletion src/Jodit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,18 @@ import FileBrowser from "./modules/FileBrowser";
import Uploader from "./modules/Uploader";
import {Config} from "./Config";

declare let appVersion: string;

interface JoditPlugin{
destruct?: Function;
open?: Function;
}

/** Class Jodit. Main class*/
export default class Jodit extends Component{
version: string = appVersion;


static defaultOptions: Config;
static plugins: any = {};
static modules: any = {};
Expand Down Expand Up @@ -632,7 +637,7 @@ export default class Jodit extends Component{
* @return {string}
*/
getVersion = () => {
return '3.0.1';
return this.version;
}
}

Expand Down
6 changes: 1 addition & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,7 @@ requireAll(require.context('./styles/plugins/', true, /\.less$/));
const context = require.context('./styles/icons/', true, /\.svg$/);

context.keys().forEach(function (key) {
Toolbar.icons[key.replace('.svg', '').replace('./', '')] = context.apply(this, arguments)
.replace(/(version|id)="[^"]+"/gm, '')
.replace(/xmlns="http:\/\/www.w3.org\/2000\/svg"/gm, '')
.replace(/xmlns:xlink="http:\/\/www.w3.org\/1999\/xlink"/gm, '')
.replace(/<!--.*-->/gm, '');
Toolbar.icons[key.replace('.svg', '').replace('./', '')] = context.apply(this, arguments);
});

const context2 = require.context('./modules/', true, /\.ts/);
Expand Down
2 changes: 0 additions & 2 deletions src/modules/FileBrowser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -320,8 +320,6 @@ export type FileBrowserCallBcackData = {
};

declare module "../Config" {


interface Config {
filebrowser: FileBrowserOptions
}
Expand Down
2 changes: 1 addition & 1 deletion src/styles/icons/about.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
35 changes: 1 addition & 34 deletions src/styles/icons/addcolumn.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
65 changes: 1 addition & 64 deletions src/styles/icons/addrow.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/angle-left.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/angle-right.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/arrows-alt.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/arrows-h.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/attachment.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/bin.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/bold.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/brush.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/cancel.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/center.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/chain-broken.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/styles/icons/check-square.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 6f6da66

Please sign in to comment.