diff --git a/README.md b/README.md index 416402b2f..c45756b38 100644 --- a/README.md +++ b/README.md @@ -76,13 +76,8 @@ git clone https://github.com/NativeScript/nativescript-sdk-examples-js.git git clone https://github.com/NativeScript/nativescript-sdk-examples-ng.git git clone https://github.com/NativeScript/nativescript-cli.git -git clone https://github.com/NativeScript/nativescript-ui-listview -git clone https://github.com/NativeScript/nativescript-ui-autocomplete -git clone https://github.com/NativeScript/nativescript-ui-dataform -git clone https://github.com/NativeScript/nativescript-ui-chart -git clone https://github.com/NativeScript/nativescript-ui-calendar -git clone https://github.com/NativeScript/nativescript-ui-gauge -git clone https://github.com/NativeScript/nativescript-ui-sidedrawer +git clone https://github.com/telerik/nativescript-ui-samples.git +git clone https://github.com/telerik/nativescript-ui-samples-angular.git ``` > **NOTE**: `nativescript-ui-...` are private repositories used for building the Api Reference for the NativeScript UI components. diff --git a/build/build-docs.sh b/build/build-docs.sh index 92905ebdb..6bd746dbd 100755 --- a/build/build-docs.sh +++ b/build/build-docs.sh @@ -15,14 +15,9 @@ SDK_ROOT_JS=$SCRIPT_PATH"/../../nativescript-sdk-examples-js" SDK_ROOT_NG=$SCRIPT_PATH"/../../nativescript-sdk-examples-ng" CLI_ROOT=$SCRIPT_PATH"/../../nativescript-cli" VUEJS_ROOT=$SCRIPT_PATH"/../../docs/vuejs-docs" -NS_UI_LV=$SCRIPT_PATH"/../../nativescript-ui-listview" -NS_UI_AC=$SCRIPT_PATH"/../../nativescript-ui-autocomplete" -NS_UI_DF=$SCRIPT_PATH"/../../nativescript-ui-dataform" -NS_UI_CH=$SCRIPT_PATH"/../../nativescript-ui-chart" -NS_UI_CA=$SCRIPT_PATH"/../../nativescript-ui-calendar" -NS_UI_GA=$SCRIPT_PATH"/../../nativescript-ui-gauge" -NS_UI_SD=$SCRIPT_PATH"/../../nativescript-ui-sidedrawer" -NS_UI_API_REF=$DOCS_ROOT"/ns_ui_api-reference" +NS_UI_SM=$SCRIPT_PATH"/../../nativescript-ui-samples" +NS_UI_SM_NG=$SCRIPT_PATH"/../../nativescript-ui-samples-angular" +NS_UI_DOCS=$DOCS_ROOT"/ns_ui_docs" [ ! -d "$ROOT" ] && rm -rf $ROOT @@ -51,33 +46,8 @@ $VUEJS_ROOT"/_plugins/snippet.rb" \ $VUEJS_ROOT"/_plugins/ns_cookbook.rb" # NativeScript UI Docs Api Reference build. Docs snippet injecting -declare -a examples=($NS_UI_AC $NS_UI_CA $NS_UI_CH $NS_UI_DF $NS_UI_GA $NS_UI_LV $NS_UI_SD) - -for i in "${examples[@]}" -do - if [ -d $i ]; then - cd $i - # Generating Angular d.ts - cd "src" - npm i --ignore-scripts - cd "angular" - tsc - - cd "../../demo" - npm install markdown-snippet-injector - # cd app - # tsc - # cd ../ - npm run inject - cd "../demo-angular" - npm install markdown-snippet-injector - npm run inject - atLeastOneNSUIExists=1 - fi -done - -if [ -n "$atLeastOneNSUIExists" -a -d $NS_UI_API_REF ]; then - cd $NS_UI_API_REF +if [ -d $NS_UI_DOCS ] && [ -d $NS_UI_SM ] && [ -d $NS_UI_SM_NG ]; then + cd $NS_UI_DOCS npm i gulp fi @@ -140,9 +110,9 @@ cd $ROOT [ ! -d $MODULES_ROOT ] || cp -R $MODULES_ROOT"/bin/dist/api-reference" $WWW_ROOT [ ! -d $NG_ROOT ] || cp -R $NG_ROOT"/nativescript-angular/bin/dist/ng-api-reference" $WWW_ROOT -if [ -d $NS_UI_LV ]; then - if [ -d $NS_UI_API_REF"/ns-ui-api-reference" ]; then - cp -R $NS_UI_API_REF"/ns-ui-api-reference" \ +if [ -d $NS_UI_DOCS ] && [ -d $NS_UI_SM ] && [ -d $NS_UI_SM_NG ]; then + if [ -d $NS_UI_DOCS"/ns-ui-api-reference" ]; then + cp -R $NS_UI_DOCS"/ns-ui-api-reference" \ $WWW_ROOT fi fi diff --git a/build/docs-watcher/paths.js b/build/docs-watcher/paths.js index 638c51f9e..d9323104a 100644 --- a/build/docs-watcher/paths.js +++ b/build/docs-watcher/paths.js @@ -11,13 +11,8 @@ module.exports.modulesRoot = path.join(module.exports.root, "..", "..", "NativeS module.exports.nativescriptAngularRoot = path.join(module.exports.root, "..", "..", "nativescript-angular"); module.exports.sdkExamplesRootNG = path.join(module.exports.root, "..", "..", "nativescript-sdk-examples-ng"); module.exports.sdkExamplesRootJS = path.join(module.exports.root, "..", "..", "nativescript-sdk-examples-js"); -module.exports.nsUIListView = path.join(module.exports.root, "..", "..", "nativescript-ui-listview"); -module.exports.nsUIAutoComplete = path.join(module.exports.root, "..", "..", "nativescript-ui-autocomplete"); -module.exports.nsUIDataForm = path.join(module.exports.root, "..", "..", "nativescript-ui-dataform"); -module.exports.nsUIChart = path.join(module.exports.root, "..", "..", "nativescript-ui-chart"); -module.exports.nsUICalendar = path.join(module.exports.root, "..", "..", "nativescript-ui-calendar"); -module.exports.nsUIGauge = path.join(module.exports.root, "..", "..", "nativescript-ui-gauge"); -module.exports.nsUISideDrawer = path.join(module.exports.root, "..", "..", "nativescript-ui-sidedrawer"); +module.exports.nsUISamples = path.join(module.exports.root, "..", "..", "nativescript-ui-samples"); +module.exports.nsUISamplesAngular = path.join(module.exports.root, "..", "..", "nativescript-ui-samples-angular"); module.exports.cliRoot = path.join(module.exports.root, "..", "..", "nativescript-cli"); module.exports.vuejsRoot = path.join(module.exports.root, "..", "vuejs-docs"); @@ -35,11 +30,6 @@ module.exports.sourcePathsInImage = [ `${module.exports.sourceFilesRoot}/nativescript-cli`, `${module.exports.sourceFilesRoot}/nativescript-sdk-examples-js`, `${module.exports.sourceFilesRoot}/nativescript-sdk-examples-ng`, - `${module.exports.sourceFilesRoot}/nativescript-ui-autocomplete`, - `${module.exports.sourceFilesRoot}/nativescript-ui-calendar`, - `${module.exports.sourceFilesRoot}/nativescript-ui-chart`, - `${module.exports.sourceFilesRoot}/nativescript-ui-dataform`, - `${module.exports.sourceFilesRoot}/nativescript-ui-gauge`, - `${module.exports.sourceFilesRoot}/nativescript-ui-listview`, - `${module.exports.sourceFilesRoot}/nativescript-ui-sidedrawer`, + `${module.exports.sourceFilesRoot}/nativescript-ui-samples`, + `${module.exports.sourceFilesRoot}/nativescript-ui-sidedrawer-angular`, ]; diff --git a/build/docs-watcher/start.sh b/build/docs-watcher/start.sh index 907b99a92..352caa90b 100755 --- a/build/docs-watcher/start.sh +++ b/build/docs-watcher/start.sh @@ -36,13 +36,8 @@ rsync --relative -az --exclude node_modules/ --exclude .git \ [ ! -d /root/./nativescript-sdk-examples-ng ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-sdk-examples-ng /www [ ! -d /root/./nativescript-sdk-examples-js ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-sdk-examples-js /www [ ! -d /root/./nativescript-cli ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-cli /www -[ ! -d /root/./nativescript-ui-listview ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-listview /www -[ ! -d /root/./nativescript-ui-autocomplete ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-autocomplete /www -[ ! -d /root/./nativescript-ui-dataform ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-dataform /www -[ ! -d /root/./nativescript-ui-chart ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-chart /www -[ ! -d /root/./nativescript-ui-calendar ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-calendar /www -[ ! -d /root/./nativescript-ui-gauge ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-gauge /www -[ ! -d /root/./nativescript-ui-sidedrawer ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-sidedrawer /www +[ ! -d /root/./nativescript-ui-samples ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-samples /www +[ ! -d /root/./nativescript-ui-samples-angular ] || rsync --relative -az --exclude node_modules/ --exclude .git /root/./nativescript-ui-samples-angular /www /www/docs/build/build-docs.sh /www/docs/build/nginx-setup.sh diff --git a/build/docs-watcher/watchers.js b/build/docs-watcher/watchers.js index 9953e6833..abb5d2f7e 100644 --- a/build/docs-watcher/watchers.js +++ b/build/docs-watcher/watchers.js @@ -34,19 +34,9 @@ module.exports.WatcherService = class WatcherService { distPaths: [`${paths.cliRoot}/./docs-cli`], buildScript: `${paths.cliRoot}/docs/build-jekyll-md.sh` }, { - basePath: path.normalize(paths.nsUIListView) + basePath: path.normalize(paths.nsUISamples) }, { - basePath: path.normalize(paths.nsUIAutoComplete) - }, { - basePath: path.normalize(paths.nsUIDataForm) - }, { - basePath: path.normalize(paths.nsUIChart) - }, { - basePath: path.normalize(paths.nsUICalendar) - }, { - basePath: path.normalize(paths.nsUIGauge) - }, { - basePath: path.normalize(paths.nsUISideDrawer) + basePath: path.normalize(paths.nsUISamplesAngular) }]; } @@ -60,13 +50,8 @@ module.exports.WatcherService = class WatcherService { `${paths.nativescriptAngularRoot}/bin/dist/**`, `${paths.sdkExamplesRootNG}/dist/**`, `${paths.sdkExamplesRootJS}/dist/**`, - `${paths.nsUIListView}/dist/**`, - `${paths.nsUIAutoComplete}/dist/**`, - `${paths.nsUIDataForm}/dist/**`, - `${paths.nsUIChart}/dist/**`, - `${paths.nsUICalendar}/dist/**`, - `${paths.nsUIGauge}/dist/**`, - `${paths.nsUISideDrawer}/dist/**`, + `${paths.nsUISamples}/dist/**`, + `${paths.nsUISamplesAngular}/dist/**`, "**/node_modules/**", "**/.*", "**/.git/**" diff --git a/ns_ui_api-reference/README.md b/ns_ui_api-reference/README.md deleted file mode 100644 index 60fd7f346..000000000 --- a/ns_ui_api-reference/README.md +++ /dev/null @@ -1,41 +0,0 @@ -# Welcome to Progress NativeScript UI -Progress NativeScript UI is a suite of UI components targeting the NativeScript platform. The controls are based on the familiar [Progress Telerik UI for Android](http://www.telerik.com/android-ui) and [Progress Telerik UI for iOS](http://www.telerik.com/ios-ui) suites and expose common API for utilizing these suites Android and iOS cross-platform development. - -# Overview -## Distribution -[**Progress NativeScript UI**](https://www.nativescript.org/ui-for-nativescript) is a set of components that enable implementing rich-ui applications for iOS and Android by using [NativeScript](http://www.nativescript.org). **Progress NativeScript UI** is built on top of natively implemented components targeting iOS and Android. - -## Getting started -For more information on how to use Progress NativeScript UI, please visit the documentation website here [http://docs.telerik.com/devtools/nativescript-ui](http://docs.telerik.com/devtools/nativescript-ui). - -## How is Progress NativeScript UI distributed -**Progress NativeScript UI** is distributed via npm. You may download the package that contains the component that you want to use from the following locations: - -- **Calendar**: https://www.npmjs.com/package/nativescript-ui-calendar -- **Chart**: https://www.npmjs.com/package/nativescript-ui-chart -- **ListView**: https://www.npmjs.com/package/nativescript-ui-listview -- **DataForm**: https://www.npmjs.com/package/nativescript-ui-dataform -- **SideDrawer**: https://www.npmjs.com/package/nativescript-ui-sidedrawer -- **Gauge**: https://www.npmjs.com/package/nativescript-ui-gauge -- **AutoComplete**: https://www.npmjs.com/package/nativescript-ui-autocomplete - -For more information about how to install these packages in a NativeScript application, take a look at the [Getting Started](http://docs.telerik.com/devtools/nativescript-ui/getting-started) article. - -> If you have been using one of the old plugins `nativescript-telerik-ui-pro`, `nativescript-telerik-ui` or `nativescript-pro-ui` you can read how to migrate to the new plugins [here](http://docs.telerik.com/devtools/nativescript-ui/migration). - -## Further resources - -### SDK samples app -You can use the Progress NativeScript UI getting started application, which is publicly available on GitHub here: [http://www.github.com/telerik/nativescript-ui-samples](http://www.github.com/telerik/nativescript-ui-samples). This application contains various examples of the usage of the components in the suite. More information about how to run the application is available on its [GitHub page](http://www.github.com/telerik/nativescript-ui-samples). - -### SDK Angular samples app -You can use the Progress NativeScript UI getting started application for Angular, which is publicly available on GitHub here: [http://www.github.com/telerik/nativescript-ui-samples-angular](http://www.github.com/telerik/nativescript-ui-samples-angular). This application contains various examples of the usage of the components in the suite. More information about how to run the application is available on its [GitHub page](http://www.github.com/telerik/nativescript-ui-samples-angular). - -### AppStore/PlayStore sample app -In case you want to experience the native side of NativeScript and UI for NativeScript to the fullest, you can refer to the official sample NativeScript application. You can find its source code at [this GitHub repo](https://github.com/NativeScript/nativescript-marketplace-demo). You can easily check how the app works on your device by getting it from [AppStore](https://itunes.apple.com/us/app/examples-nativescript/id1046772499?ls=1&mt=8) or [PlayStore](https://play.google.com/store/apps/details?id=org.nativescript.examples). - -## Feedback -Your feedback will be highly appreciated and will directly influence the development of **Progress NativeScript UI**. - -You can submit issues and feedback at the dedicated feedback GitHub repository here: -[https://github.com/telerik/nativescript-ui-feedback](https://github.com/telerik/nativescript-ui-feedback) diff --git a/ns_ui_api-reference/gulpfile.js b/ns_ui_api-reference/gulpfile.js deleted file mode 100644 index 13e4d601f..000000000 --- a/ns_ui_api-reference/gulpfile.js +++ /dev/null @@ -1,30 +0,0 @@ -var gulp = require('gulp'); -// var typeScript = require('gulp-typescript'); -var typedoc = require('gulp-typedoc'); - -gulp.task("default", function() { - return gulp - .src(["./../../nativescript-ui-listview/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-autocomplete/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-dataform/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-chart/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-calendar/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-gauge/**/{index,angular/index,angular/*-directives}.d.ts", - "./../../nativescript-ui-sidedrawer/**/{index,angular/index,angular/*-directives}.d.ts"]) - .pipe(typedoc({ - // TypeScript options (see typescript docs) - module: "commonjs", - mode: "file", - target: "es5", - includeDeclarations: true, - excludeExternals: true, - - // Output options (see typedoc docs) - out: "./ns-ui-api-reference", - // TypeDoc options (see typedoc docs) - name: "Progress NativeScript UI API", - ignoreCompilerErrors: true, - theme: "./node_modules/nativescript-typedoc-theme", - readme: "./README.md" - })); -}); diff --git a/ns_ui_api-reference/package.json b/ns_ui_api-reference/package.json deleted file mode 100644 index 351d5cbdf..000000000 --- a/ns_ui_api-reference/package.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "name": "nativescript-ui-build-environment", - "version": "1.0.0", - "author": "Progress AD", - "dependencies": { - "gulp": "4.0.0", - "gulp-typedoc": "2.2.1", - "nativescript-typedoc-theme": "git://github.com/NativeScript/nativescript-typedoc-theme.git#master", - "typedoc": "0.14.2" - } -} diff --git a/ns_ui_docs/gulpfile.js b/ns_ui_docs/gulpfile.js new file mode 100644 index 000000000..975615d09 --- /dev/null +++ b/ns_ui_docs/gulpfile.js @@ -0,0 +1,35 @@ +var gulp = require('gulp'); +var typedoc = require('gulp-typedoc'); +var run = require('gulp-run-command').default; + +gulp.task("snippet-mdinject", run('mdinject --root=./../../nativescript-ui-samples --docsroot=./../docs/ui/professional-ui-components --sourceext=".ts|.js|.xml|.css" --snippettitles="TypeScript|JavaScript|XML|CSS"')); +gulp.task("snippet-mdinject-ng", run('mdinject --root=./../../nativescript-ui-samples-angular --docsroot=./../docs/ui/professional-ui-components --sourceext=".ts|.js|.xml|.css" --snippettitles="TypeScript|JavaScript|XML|CSS"')); + +gulp.task("ns-ui-api-ref-build", function () { + return gulp + .src(["./node_modules/nativescript-ui-listview/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-autocomplete/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-dataform/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-chart/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-calendar/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-gauge/{index,angular/index,angular/*-directives}.d.ts", + "./node_modules/nativescript-ui-sidedrawer/{index,angular/index,angular/*-directives}.d.ts"]) + .pipe(typedoc({ + // TypeScript options (see typescript docs) + module: "commonjs", + mode: "file", + target: "es5", + includeDeclarations: true, + excludeExternals: true, + + // Output options (see typedoc docs) + out: "./ns-ui-api-reference", + // TypeDoc options (see typedoc docs) + name: "Progress NativeScript UI API", + ignoreCompilerErrors: true, + theme: "./node_modules/nativescript-typedoc-theme", + readme: "./README.md" + })); +}); + +gulp.task("default", gulp.series("snippet-mdinject", "snippet-mdinject-ng", "ns-ui-api-ref-build")); \ No newline at end of file diff --git a/ns_ui_docs/package.json b/ns_ui_docs/package.json new file mode 100644 index 000000000..f906b146a --- /dev/null +++ b/ns_ui_docs/package.json @@ -0,0 +1,20 @@ +{ + "name": "nativescript-ui-build-environment", + "version": "1.0.0", + "author": "Progress AD", + "dependencies": { + "gulp": "4.0.0", + "gulp-typedoc": "2.2.1", + "markdown-snippet-injector": "^0.2.2", + "gulp-run-command": "0.0.9", + "nativescript-typedoc-theme": "git://github.com/NativeScript/nativescript-typedoc-theme.git#master", + "typedoc": "0.14.2", + "nativescript-ui-listview":"*", + "nativescript-ui-autocomplete":"*", + "nativescript-ui-dataform":"*", + "nativescript-ui-chart":"*", + "nativescript-ui-calendar":"*", + "nativescript-ui-gauge":"*", + "nativescript-ui-sidedrawer":"*" + } +}