Skip to content

Commit

Permalink
Merge pull request #146 from iLib-js/development
Browse files Browse the repository at this point in the history
Merge to master to make build 14.1.0
  • Loading branch information
ehoogerbeets authored Oct 19, 2018
2 parents 00464cf + c7397ed commit f6c40df
Show file tree
Hide file tree
Showing 138 changed files with 18,274 additions and 18,199 deletions.
2 changes: 1 addition & 1 deletion build.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.

version=14.0.0
version=14.1.0
17 changes: 17 additions & 0 deletions docs/ReleaseNotes.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,23 @@
Release Notes for Version 14
============================

Build 002
-------
Published as version 14.1.0

New Features:
* New top-level entry point
* You can now require("ilib") directly instead of requiring the file that installs the loader. (ie.
ilib/lib/ilib-node.js for node, or ilib/lib/ilib-qt.js for qt, etc.)
* The top-level entry point will figure out which environment it is running in and automatically install
the appropriate loader.
* Allows ilib to run in node or within a webpack bundle without changes
* Allows clients to just require ilib classes directly without first requiring the loader installer

Bug Fixes
* Restored a missing mapping from the the native name for "Japan" to the ISO code "JP" in the nativecountries.json
* Fixes address parsing for Japan

Build 001
-------
Published as version 14.0.0
Expand Down
11 changes: 10 additions & 1 deletion js/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -342,8 +342,10 @@ limitations under the License.
<fileset dir="${build.lib}">
<include name="ilib-node*"/>
<include name="ilib-qt*"/>
<include name="ilib-getdata.js"/>
<include name="ilib-unpack.js"/>
</fileset>
<fileset dir="${build.base}">
<include name="index.js"/>
</fileset>
<mapper type="glob" from="*.js" to="*.js"/>
</apply>
Expand Down Expand Up @@ -467,6 +469,7 @@ limitations under the License.
<copy todir="${build.export}/src/js">
<fileset dir="${build.base}">
<include name="lib/**"/>
<include name="index.js"/>
<include name="build.xml"/>
<include name="build.properties"/>
<include name="data/locale/**/*.json"/>
Expand Down Expand Up @@ -494,6 +497,7 @@ limitations under the License.
<exclude name="ilib-qt.js"/>
<exclude name="ilib-rhino.js"/>
<exclude name="ilib-enyo.js"/>
<exclude name="index.js"/>
</fileset>
<fileset dir="${build.export}/js/dyncode">
<include name="Loader.js"/>
Expand All @@ -506,6 +510,11 @@ limitations under the License.
<include name="ilib-full-dyn-compiled.js"/>
</fileset>
</copy>
<copy todir="${build.export}/package">
<fileset dir="${build.export}/js/dyncode">
<include name="index.js"/>
</fileset>
</copy>
<copy todir="${build.export}/package/locale">
<fileset dir="${build.locale}">
<include name="**/*.json"/>
Expand Down
57 changes: 57 additions & 0 deletions js/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
/*
* index.js - top level entry point for ilib
*
* Copyright © 2018 JEDLSoft
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*
* See the License for the specific language governing permissions and
* limitations under the License.
*/

var ilib = require("./lib/ilib.js");

if (!ilib._platform || (typeof(ilib._dyndata) !== 'boolean' && typeof(ilib._dyncode) !== 'boolean')) {
if (typeof(__webpack_require__) !== 'undefined') {
// The following will either require and then install the
// WebpackLoader to dynamically load locale data bundles,
// or it will statically require all of the locale data that
// this build needs so that it can be included into this
// webpack bundle.

// !defineLocaleData
} else {
switch (ilib._getPlatform()) {
case 'webos':
case 'nodejs':
require("./lib/ilib-node.js");
break;

case 'qt':
require("./lib/ilib-qt.js");

case 'rhino':
require("./lib/ilib-rhino.js");
break;

case 'ringo':
require("./lib/ilib-ringo.js");
break;

default:
ilib._dyncode = false;
ilib._dyndata = false;
break;
}
}
}

module.exports = ilib;
Loading

0 comments on commit f6c40df

Please sign in to comment.