Skip to content

Commit

Permalink
feat(build)!: use a compromise solution
Browse files Browse the repository at this point in the history
BREAKING CHANGE: This basically reverts the most breaking parts of the
previosly commited overhaul.

Use a compromise solution between backwards compatibility and easy of
maintenance. The old exports are restored and so is the file listing in
the package. However the libraries themselves may still introduce
breaking changes in their features etc.
  • Loading branch information
Thomaash committed May 17, 2020
1 parent e8bb08c commit 0d8d8e3
Show file tree
Hide file tree
Showing 34 changed files with 623 additions and 102 deletions.
6 changes: 1 addition & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,7 @@ jobs:
- persist_to_workspace:
root: .
paths:
- declarations
- esnext
- peer
- standalone
- styles"
- dist

test:
executor: node
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ report.*.json
vis-charts-*.tgz
/.rpt2_cache/
/declarations/
/dist/
/esnext/
/examples/examples.css
/examples/generated/
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# vis-charts

**This is mostly (same export structure) a "plug'n & play replacement" for [vis](https://github.com/almende/vis), wich is no longer maintained**

Vis.js is a dynamic, browser based visualization library.
The library is designed to be easy to use, handle large amounts
of dynamic data, and enable manipulation of the data.
Expand Down Expand Up @@ -29,8 +31,6 @@ It also includes other external libraries:

## Badges

[![Greenkeeper badge](https://badges.greenkeeper.io/visjs/vis-charts.svg)](https://greenkeeper.io/)

[![Backers on Open Collective](https://opencollective.com/visjs/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/visjs/sponsors/badge.svg)](#sponsors)

## Usage
Expand Down
2 changes: 1 addition & 1 deletion babel.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
exclude: require("vis-dev-utils").BABEL_IGNORE_RE,
presets: [["vis-dev-utils/babel-preset", { css: false }]]
presets: [["vis-dev-utils/babel-preset", { css: true }]]
};
1 change: 1 addition & 0 deletions examples/all.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<title>Charts | All</title>

<script src="../standalone/umd/vis-charts.min.js"></script>
<link href="../styles/vis-charts.min.css" rel="stylesheet" type="text/css" />

<style type="text/css">
body,
Expand Down
1 change: 1 addition & 0 deletions examples/graph3d.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<title>Charts | Graph3D</title>

<script src="../standalone/umd/vis-charts.min.js"></script>
<link href="../styles/vis-charts.min.css" rel="stylesheet" type="text/css" />

<style type="text/css">
body {
Expand Down
1 change: 1 addition & 0 deletions examples/network.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<title>Charts | Network</title>

<script src="../standalone/umd/vis-charts.min.js"></script>
<link href="../styles/vis-charts.min.css" rel="stylesheet" type="text/css" />

<style type="text/css">
#chart {
Expand Down
Binary file added legacy-files/img/network/acceptDeleteIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/addNodeIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/backIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/connectIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/cross.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/cross2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/deleteIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/downArrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/editIcon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/leftArrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/minus.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/plus.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/rightArrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/upArrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added legacy-files/img/network/zoomExtends.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
33 changes: 18 additions & 15 deletions lib/header.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import moment from 'moment';
import pkg from '../package.json';
import moment from "moment";
import pkg from "../package.json";

const header = `
${ pkg.homepage }
${pkg.homepage}
${ pkg.description }
${pkg.description}
@version ${ pkg.version }
@date ${ moment().utc().format() }
@version ${pkg.version}
@date ${moment()
.utc()
.format()}
@copyright (c) 2011-2017 Almende B.V, http://almende.com
@copyright (c) 2018-2019 visjs contributors, https://github.com/visjs
Expand All @@ -27,18 +29,19 @@ vis.js may be distributed under either license.`;

/**
* Generate a dynamic header banner.
*
* @param {String} component
*
* @param {String} component
* @returns {String} banner
*/
function genHeader(component) {
return '/*\n' + [
pkg.name,
component ? ' - ' + component : '',
header
].join('')
.replace(/^(?!\n)/gm, ' * ')
.replace(/^(?=\n)/gm, ' *') + '\n */';
return (
"/*\n" +
[pkg.name, component ? " - " + component : "", header]
.join("")
.replace(/^(?!\n)/gm, " * ")
.replace(/^(?=\n)/gm, " *") +
"\n */"
);
}

export default genHeader;
Loading

0 comments on commit 0d8d8e3

Please sign in to comment.