diff --git a/.bowerrc b/.bowerrc deleted file mode 100644 index b5ecdd172..000000000 --- a/.bowerrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "directory": "lib" -} diff --git a/.editorconfig b/.editorconfig deleted file mode 100644 index 940d287e4..000000000 --- a/.editorconfig +++ /dev/null @@ -1,15 +0,0 @@ -# This file is for unifying the coding style for different editors and IDEs -# editorconfig.org - -root = true - -[*] -end_of_line = lf -charset = utf-8 -trim_trailing_whitespace = true -insert_final_newline = true -indent_style = space -indent_size = 2 - -[*.md] -trim_trailing_whitespace = false diff --git a/.gitattributes b/.gitattributes deleted file mode 100644 index fbf9358b0..000000000 --- a/.gitattributes +++ /dev/null @@ -1,14 +0,0 @@ -# Set the default behavior, in case people don't have core.autocrlf set. -* text=auto - -# Explicitly declare text files you want to always be normalized and converted -# to native line endings on checkout. -*.c text -*.h text - -# Declare files that will always have CRLF line endings on checkout. -*.sln text eol=crlf - -# Denote all files that are truly binary and should not be modified. -*.png binary -*.jpg binary diff --git a/.github/PULL_REQUEST_TEMPLATE b/.github/PULL_REQUEST_TEMPLATE deleted file mode 100644 index 4279d166f..000000000 --- a/.github/PULL_REQUEST_TEMPLATE +++ /dev/null @@ -1,9 +0,0 @@ -## Description -State the overall goal of the pull request. Describe the list of changes the PR introduces and include any related PRs, Issues and/or Jira stories. - -## PR Checklist - -- [ ] Unit tests are included -- [ ] Screenshots are attached (if there are visual changes in the UI) -- [ ] A Designer (@beanh66) is assigned as a reviewer (if there are visual changes in the UI) -- [ ] A CSS rep (@cshinn) is assigned as a reviewer (if there are visual changes in the UI) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md deleted file mode 100644 index 4279d166f..000000000 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ /dev/null @@ -1,9 +0,0 @@ -## Description -State the overall goal of the pull request. Describe the list of changes the PR introduces and include any related PRs, Issues and/or Jira stories. - -## PR Checklist - -- [ ] Unit tests are included -- [ ] Screenshots are attached (if there are visual changes in the UI) -- [ ] A Designer (@beanh66) is assigned as a reviewer (if there are visual changes in the UI) -- [ ] A CSS rep (@cshinn) is assigned as a reviewer (if there are visual changes in the UI) diff --git a/.gitignore b/.gitignore deleted file mode 100644 index f164c6516..000000000 --- a/.gitignore +++ /dev/null @@ -1,12 +0,0 @@ -node_modules -lib -.tmp -coverage -docs -dist -test-results.xml -npm-debug.log - -.idea/* -*.iml -.vscode diff --git a/.htmlhintrc b/.htmlhintrc deleted file mode 100644 index d97f35495..000000000 --- a/.htmlhintrc +++ /dev/null @@ -1,12 +0,0 @@ -{ - "tagname-lowercase": true, - "attr-lowercase": true, - "attr-value-doublequotes": true, - "tag-pair": true, - "tag-self-close": true, - "id-unique": true, - "src-not-empty": true, - "style-disabled": true, - "img-alt-require": true, - "spec-char-escape": true -} diff --git a/.npmignore b/.npmignore deleted file mode 100644 index db918b452..000000000 --- a/.npmignore +++ /dev/null @@ -1,47 +0,0 @@ -# generic (system) files/extensions we don't want -*.seed -*.log -*.csv -*.dat -*.out -*.pid -*.gz -.idea/* -*.iml -*.DS_Store -lib-cov -pids -logs -results -test-results.xml -dist/docs/components -dist/docs/font* -dist/docs/grunt-styles -dist/docs/img -dist/docs/index.html - - -docs -node_modules -npm-debug.log -lib -.bower - - -.openshift -/misc -/scripts -/src -/styles -test -.bowerrc -.editorconfig -.gitattributes -.htmlhintrc -.travis.yml -bower.json -deploy_key.enc -eslint.yaml -grunt-ngdocs-index.tmpl -Gruntfile.js -/server.js diff --git a/.openshift/README.md b/.openshift/README.md deleted file mode 100644 index 7ec66d79d..000000000 --- a/.openshift/README.md +++ /dev/null @@ -1,3 +0,0 @@ -For information about .openshift directory, consult the documentation: - -http://openshift.github.io/documentation/oo_user_guide.html#the-openshift-directory diff --git a/.openshift/action_hooks/README.md b/.openshift/action_hooks/README.md deleted file mode 100644 index 541319581..000000000 --- a/.openshift/action_hooks/README.md +++ /dev/null @@ -1,3 +0,0 @@ -For information about action hooks, consult the documentation: - -http://openshift.github.io/documentation/oo_user_guide.html#action-hooks diff --git a/.openshift/cron/README.cron b/.openshift/cron/README.cron deleted file mode 100644 index ac77f7872..000000000 --- a/.openshift/cron/README.cron +++ /dev/null @@ -1,27 +0,0 @@ -Run scripts or jobs on a periodic basis -======================================= -Any scripts or jobs added to the minutely, hourly, daily, weekly or monthly -directories will be run on a scheduled basis (frequency is as indicated by the -name of the directory) using run-parts. - -run-parts ignores any files that are hidden or dotfiles (.*) or backup -files (*~ or *,) or named *.{rpmsave,rpmorig,rpmnew,swp,cfsaved} - -The presence of two specially named files jobs.deny and jobs.allow controls -how run-parts executes your scripts/jobs. - jobs.deny ===> Prevents specific scripts or jobs from being executed. - jobs.allow ===> Only execute the named scripts or jobs (all other/non-named - scripts that exist in this directory are ignored). - -The principles of jobs.deny and jobs.allow are the same as those of cron.deny -and cron.allow and are described in detail at: - http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/ch-Automating_System_Tasks.html#s2-autotasks-cron-access - -See: man crontab or above link for more details and see the the weekly/ - directory for an example. - -PLEASE NOTE: The Cron cartridge must be installed in order to run the configured jobs. - -For more information about cron, consult the documentation: -http://openshift.github.io/documentation/oo_cartridge_guide.html#cron -http://openshift.github.io/documentation/oo_user_guide.html#cron diff --git a/.openshift/cron/daily/.gitignore b/.openshift/cron/daily/.gitignore deleted file mode 100644 index e69de29bb..000000000 diff --git a/.openshift/cron/hourly/.gitignore b/.openshift/cron/hourly/.gitignore deleted file mode 100644 index e69de29bb..000000000 diff --git a/.openshift/cron/minutely/.gitignore b/.openshift/cron/minutely/.gitignore deleted file mode 100644 index e69de29bb..000000000 diff --git a/.openshift/cron/monthly/.gitignore b/.openshift/cron/monthly/.gitignore deleted file mode 100644 index e69de29bb..000000000 diff --git a/.openshift/cron/weekly/README b/.openshift/cron/weekly/README deleted file mode 100644 index 7c3e659fe..000000000 --- a/.openshift/cron/weekly/README +++ /dev/null @@ -1,16 +0,0 @@ -Run scripts or jobs on a weekly basis -===================================== -Any scripts or jobs added to this directory will be run on a scheduled basis -(weekly) using run-parts. - -run-parts ignores any files that are hidden or dotfiles (.*) or backup -files (*~ or *,) or named *.{rpmsave,rpmorig,rpmnew,swp,cfsaved} and handles -the files named jobs.deny and jobs.allow specially. - -In this specific example, the chronograph script is the only script or job file -executed on a weekly basis (due to white-listing it in jobs.allow). And the -README and chrono.dat file are ignored either as a result of being black-listed -in jobs.deny or because they are NOT white-listed in the jobs.allow file. - -For more details, please see ../README.cron file. - diff --git a/.openshift/cron/weekly/chronograph b/.openshift/cron/weekly/chronograph deleted file mode 100755 index 61de949f4..000000000 --- a/.openshift/cron/weekly/chronograph +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash - -echo "`date`: `cat $(dirname \"$0\")/chrono.dat`" diff --git a/.openshift/cron/weekly/jobs.allow b/.openshift/cron/weekly/jobs.allow deleted file mode 100644 index 8d32abc70..000000000 --- a/.openshift/cron/weekly/jobs.allow +++ /dev/null @@ -1,12 +0,0 @@ -# -# Script or job files listed in here (one entry per line) will be -# executed on a weekly-basis. -# -# Example: The chronograph script will be executed weekly but the README -# and chrono.dat files in this directory will be ignored. -# -# The README file is actually ignored due to the entry in the -# jobs.deny which is checked before jobs.allow (this file). -# -chronograph - diff --git a/.openshift/cron/weekly/jobs.deny b/.openshift/cron/weekly/jobs.deny deleted file mode 100644 index 73c945008..000000000 --- a/.openshift/cron/weekly/jobs.deny +++ /dev/null @@ -1,7 +0,0 @@ -# -# Any script or job files listed in here (one entry per line) will NOT be -# executed (read as ignored by run-parts). -# - -README - diff --git a/.openshift/markers/README.md b/.openshift/markers/README.md deleted file mode 100644 index b960abbad..000000000 --- a/.openshift/markers/README.md +++ /dev/null @@ -1,5 +0,0 @@ -For information about markers, consult the documentation: - -http://openshift.github.io/documentation/oo_user_guide.html#markers - -NOTE: To enable hot deploy, simpy create a file named hot_deploy. diff --git a/.openshift/markers/hot_deploy b/.openshift/markers/hot_deploy deleted file mode 100644 index e69de29bb..000000000 diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 3301f33cf..000000000 --- a/.travis.yml +++ /dev/null @@ -1,42 +0,0 @@ -language: node_js -node_js: - - '8' - -cache: - directories: - - node_modules - -notifications: - email: false - -env: - global: - - ENCRYPTION_LABEL: "aa286ccd339e" - - COMMIT_AUTHOR_EMAIL: "patternfly-build@redhat.com" - - TRIGGER_REPO_SLUG: "patternfly/angular-patternfly" - - TRIGGER_REPO_BRANCH: "master" - -before_install: - - npm install -g npm@5.4.0 - - npm install -g bower grunt-cli - - npm install patternfly-eng-release - -install: true - -script: - - sh -x ./node_modules/patternfly-eng-release/scripts/_build.sh -a - -after_success: - - 'if [[ "$TRAVIS_SECURE_ENV_VARS" = "true" && "$TRAVIS_BRANCH" = "master-dist" ]]; then - npm prune; - npm run semantic-release-pre; - sh -x ./node_modules/patternfly-eng-release/scripts/semantic-release/_bump.sh -a; - sh -x ./node_modules/patternfly-eng-release/scripts/semantic-release/_publish-npm.sh || travis_terminate 0; - npm run semantic-release-post; - - sh -x ./node_modules/patternfly-eng-release/scripts/semantic-release/_publish-webjar.sh -a; - fi' - - ./scripts/publish-ghpages.sh -t docs - -branches: - except: - - /^v\d+\.\d+\.\d+$/ diff --git a/Gruntfile.js b/Gruntfile.js deleted file mode 100644 index e569e5541..000000000 --- a/Gruntfile.js +++ /dev/null @@ -1,574 +0,0 @@ -module.exports = function (grunt) { - 'use strict'; - - var nodeSass = require('node-sass'); - require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); - - function init () { - - // '--sass' command line argument exists? - var sassBuild = grunt.option('sass'); - - grunt.initConfig({ - availabletasks: { - tasks: { - options: { - descriptions: { - 'help': 'Task list helper for your Grunt enabled projects.', - 'clean': 'Deletes the content of the dist directory.', - 'build': 'Builds the project (including documentation) into the dist directory. You can specify modules to be built as arguments (' + - 'grunt build:buttons:notification) otherwise all available modules are built.', - 'test': 'Executes the karma testsuite.', - 'watch': 'Whenever js source files (from the src directory) change, the tasks executes jslint and documentation build.', - 'uidocs': 'Builds documentation into docs.', - 'uidocs:view': 'Builds documentation into docs and runs a web server. The docs can be accessed on http://localhost:8000/', - 'uidocs:publish': 'Publishes the uidocs to the dist area. This should only be done when bumping the release version.' - }, - groups: { - 'Basic project tasks': ['help', 'clean', 'build', 'test'], - 'Documentation tasks': ['uidocs', 'uidocs:view', 'uidocs:publish'] - } - } - } - }, - clean: { - docs: ['docs'], - templates: ['templates/'], - all: ['dist/*', '!dist/docs'] - }, - concat: { - options: { - separator: ';' - }, - dist: { - src: ['src/**/*.module.js', 'src/**/*.js', 'templates/*.js'], - dest: 'dist/angular-patternfly.js' - } - }, - connect: { - docs: { - options: { - hostname: '0.0.0.0', - port: grunt.option("port") || 8000, - base: 'docs', - livereload: 35722, - open: true - } - } - }, - copy: { - docdata: { - cwd: 'node_modules/patternfly/dist', - src: ['fonts/*', 'img/*'], - dest: 'docs', - expand: true - }, - fa: { - cwd: 'node_modules/patternfly/', - src: ['components/font-awesome/**'], - dest: 'docs', - expand: true - }, - img: { - cwd: 'misc/', - src: ['patternfly-orb.svg','patternfly-logo.svg', 'grid-sidebar.png', '*.png'], - dest: 'docs/img', - expand: true - }, - publish: { - cwd: 'docs', - src: ['**'], - dest: 'dist/docs', - expand: true - }, - distimg: { - cwd: 'misc', - src: ['canvas-dot-grid.png'], - dest: 'dist/imgs', - expand: true - }, - distless: { - src: ['styles/**/*.less', 'src/**/*.less'], - dest: 'dist/less', - expand: true, - flatten: true - }, - distlessDependencies: { - src: ['node_modules/patternfly/dist/less/color-variables.less'], - dest: 'dist/less/dependencies/patternfly', - expand: true, - flatten: true - }, - distsass: { - src: ['styles/_angular-patternfly.scss'], - dest: 'dist/sass', - expand: true, - flatten: true - }, - sassBuild:{ - files: [ - { - // copy css built from sass into dist/styles - expand: true, - cwd: 'dist/sass', - src: ['**/*.css', '**/*.map'], - dest: 'dist/styles/' - } - ] - } - }, - 'string-replace': { - dist: { - files: [{ - cwd: 'dist/less/', - src: ['angular-patternfly.less'], - dest: 'dist/less', - expand: true - }], - options: { - replacements: [{ - pattern: /\.\.\/src\/(.*?)+\//g, - replacement: '' - },{ - pattern: '../node_modules/patternfly/dist/less', - replacement: 'dependencies/patternfly' - }] - } - } - }, - lessToSass: { - /* eslint-disable */ - convert_within_custom_replacements: { - /* eslint-enable */ - files: [ - { - expand: true, - cwd: 'styles', - src: ['**/*.less', '!angular-patternfly.less'], - dest: 'dist/sass/', - rename: function(dest, src) { - return dest + '_' + src.replace('.less', '.scss'); - } - }, - { - expand: true, - cwd: 'src', - src: ['**/*.less'], - dest: 'dist/sass/', - rename: function(dest, src) { - return dest + '_' + src.split('/').pop().replace('.less', '.scss'); - } - } - ], - options: { - excludes: ['variables', 'default'], - replacements: [ - { - // Customize variable conversion to include newer css reserved words. - pattern: /(?!@debug|@import|@media|@keyframes|@font-face|@include|@extend|@mixin|@supports|@-\w)@/gi, - replacement: '$', - order: 0 - }, - { - // Add !default flag to variable declarations without leading whitespace. - pattern: /^(\$.*?:.*?);(\s*\/\/.*)?$/mgi, - replacement: '$1 !default;$2', - order: 2 - }, - { - // Include mixins with no arguments - pattern: /(\s+)\.([\w\-]+)\(\)/gi, - replacement: '$1@include $2()', - order: 3 - }, - { - // Interpolates second ampersand where double ampersands are used - pattern: /\&\&/gi, - replacement: '&#{&}', - order: 20 - }, - { - // Interpolates ampersands that directly follow (are touching) a definition - // e.g. somedef& becomes somedef#{&} - pattern: /(\w+)\&/gi, - replacement: '$1#{&}', - order: 30 - }, - { - // Namespaced mixins are detected as includes by default conversion - // process. Remove namespacing by concatenating namespace and mixin name. - // #gradient { - // @include striped(){...} - // } - // - // becomes - // - // @mixin gradient-striped(){...} - pattern: /^#([\w\-]+)\s*{\s*@include\s*([\w\-]*)\((.*)\)\s*{([\s\S]*?)}\s*}/mgi, - replacement: '@mixin $1-$2($3){$4}', - order: 40 - }, - // Fix invocation of namespaced mixins. Replace #namespace > .mixin() - // or #namespace.mixin() with @include namespace-mixin() - { - pattern: /#(\w*)\s*\>?\s*\.(\w*)(\(.*\))/gi, - replacement: '@include $1-$2$3', - order: 50 - }, - { - // Remove "!default" flag from mixin declarations - pattern: /@mixin.*!default.*/gi, - replacement: function(match) { - return match.replace(/\s*!default\s*/gi, ''); - }, - order: 60 - }, - { - // Replace semi-colons with commas in mixins and includes - pattern: /(@mixin |@include )([\w\-]*)\s*(\(.*\))(\s*[{;]?)/gi, - replacement: function(match, p1, p2, p3, p4) { - return p1 + p2 + p3.replace(/;/g, ',') + p4; - }, - order: 70 - }, - { - // Fix bug in grunt-less-to-sass that puts "!important" inside mixin and css function parens. - pattern: /^(\s*[\w\-]*:\s*[\w\-]*)\((.*?)\s*!important.*\)(.*);(.*)$/mgi, - replacement: '$1($2) !important$3;$4', - order: 80 - }, - { - pattern: /\&:extend\((.*)\)/gi, - replacement: '@extend $1', - order: 90 - }, - ] - } - } - }, - sass: { - patternfly: { - files: { - 'dist/sass/angular-patternfly.css': ['styles/build.scss'] - }, - options: { - implementation: nodeSass, - outputStyle: 'expanded', - includePaths: [ - 'dist/sass', - 'node_modules/patternfly/dist/sass' - ] - } - } - }, - less: { - patternfly: { - files: { - 'dist/styles/angular-patternfly.css': 'styles/angular-patternfly.less' - }, - options: { - implementation: nodeSass, - paths: ['src/less/'], - strictMath: true - } - } - }, - cssmin: { - target: { - files: [{ - expand: true, - cwd: 'dist/styles', - src: ['*.css', '!*.min.css'], - dest: 'dist/styles', - ext: '.min.css' - }] - } - }, - htmlhint: { - html: { - src: ['src/**/*.html'], - options: { - htmlhintrc: '.htmlhintrc' - } - } - }, - eslint: { - standard: { - options: { - configFile: 'eslint.yaml' - }, - src : [ - 'Gruntfile.js', - 'src/**/*.js' - ] - }, - tests: { - options: { - configFile: 'test/eslint.yaml' - }, - src : [ - 'test/**/*.js' - ] - } - }, - karma: { - unit: { - configFile: 'test/karma.conf.js', - singleRun: true, - browsers: ['PhantomJS'] - } - }, - coveralls: { - options: { - debug: true, - coverageDir: 'coverage', - dryRun: false, - force: true - } - }, - 'uidocs-generator': { - options: { - title: 'ANGULAR PATTERNFLY', - dest: 'docs', - image: 'misc/logo-alt.svg', - scripts: [ - 'node_modules/jquery/dist/jquery.js', - 'node_modules/bootstrap/dist/js/bootstrap.min.js', - 'node_modules/bootstrap-select/js/bootstrap-select.js', - 'node_modules/jquery-ui-dist/jquery-ui.js', - 'node_modules/datatables.net/js/jquery.dataTables.js', - 'node_modules/datatables.net-select/js/dataTables.select.js', - 'node_modules/moment/moment.js', - 'node_modules/d3/d3.js', - 'node_modules/c3/c3.js', - 'node_modules/patternfly/dist/js/patternfly-settings.js', - 'node_modules/patternfly/dist/js/patternfly-settings-colors.js', - 'node_modules/patternfly/dist/js/patternfly-settings-charts.js', - 'node_modules/angular/angular.js', - 'node_modules/angular-dragdrop/src/angular-dragdrop.js', - 'node_modules/angularjs-datatables/dist/angular-datatables.js', - 'node_modules/angularjs-datatables/dist/plugins/select/angular-datatables.select.min.js', - 'node_modules/angular-sanitize/angular-sanitize.js', - 'node_modules/angular-animate/angular-animate.js', - 'node_modules/angular-ui-bootstrap/dist/ui-bootstrap-tpls.js', - 'misc/angular-bootstrap-prettify.js', - 'node_modules/lodash/lodash.min.js', - 'dist/angular-patternfly.js', - 'node_modules/angular-ui-router/release/angular-ui-router.min.js', - 'node_modules/angular-drag-and-drop-lists/angular-drag-and-drop-lists.js'], - html5Mode: false, - template: 'grunt-uidocs-index.tmpl', - styles: ['node_modules/datatables.net-dt/css/jquery.dataTables.css', - 'node_modules/patternfly/dist/css/patternfly.css', - 'node_modules/patternfly/dist/css/patternfly-additions.css', - 'dist/styles/angular-patternfly.css', - 'misc/patternfly-showcase.css', - 'misc/ng-docs.css', - 'misc/examples.css'] - }, - - all: ['src/**/*.js'] - }, - ngtemplates: { - options: { - htmlmin: { - collapseBooleanAttributes: true, - collapseWhitespace: true, - removeAttributeQuotes: true, - removeComments: false, - removeEmptyAttributes: true, - removeRedundantAttributes: true, - removeScriptTypeAttributes: true, - removeStyleLinkTypeAttributes: true - } - }, - 'patternfly.form': { - cwd: 'src/', - src: ['form/**/*.html'], - dest: 'templates/form.js' - }, - 'patternfly.navigation': { - cwd: 'src/', - src: ['navigation/**/*.html'], - dest: 'templates/navigation.js' - }, - 'patternfly.notification': { - cwd: 'src/', - src: ['notification/**/*.html'], - dest: 'templates/notification.js' - }, - 'patternfly.card': { - cwd: 'src/', - src: ['card/**/*.html'], - dest: 'templates/card.js' - }, - 'patternfly.charts': { - cwd: 'src/', - src: ['charts/**/*.html'], - dest: 'templates/charts.js' - }, - 'patternfly.filters': { - cwd: 'src/', - src: ['filters/**/*.html'], - dest: 'templates/filters.js' - }, - 'patternfly.modals': { - cwd: 'src/', - src: ['modals/**/*.html'], - dest: 'templates/modals.js' - }, - 'patternfly.select': { - cwd: 'src/', - src: ['select/**/*.html'], - dest: 'templates/select.js' - }, - 'patternfly.sort': { - cwd: 'src/', - src: ['sort/**/*.html'], - dest: 'templates/sort.js' - }, - 'patternfly.table': { - cwd: 'src/', - src: ['table/**/*.html'], - dest: 'templates/table.js' - }, - 'patternfly.toolbars': { - cwd: 'src/', - src: ['toolbars/**/*.html'], - dest: 'templates/toolbars.js' - }, - 'patternfly.views': { - cwd: 'src/', - src: ['views/**/*.html'], - dest: 'templates/views.js' - }, - 'patternfly.wizard': { - cwd: 'src/', - src: ['wizard/**/*.html'], - dest: 'templates/wizard.js' - }, - 'patternfly.canvas': { - cwd: 'src/', - src: ['canvas-view/**/*.html'], - dest: 'templates/canvas.js' - }, - 'patternfly.pagination': { - cwd: 'src/', - src: ['pagination/**/*.html'], - dest: 'templates/pagination.js' - }, - 'patternfly.datepicker' : { - cwd: 'src/', - src: ['datepicker/**/*.html'], - dest: 'templates/datepicker.js' - } - }, - // ng-annotate tries to make the code safe for minification automatically - // by using the Angular long form for dependency injection. - ngAnnotate: { - dist: { - files: [{ - src: 'dist/angular-patternfly.js', - dest: 'dist/angular-patternfly.js' - }] - } - }, - remove: { - published: { - dirList: ['dist/docs'] - } - }, - uglify: { - options: { - mangle: false - }, - build: { - files: {}, - src: 'dist/angular-patternfly.js', - dest: 'dist/angular-patternfly.min.js' - } - }, - watch: { - main: { - files: ['Gruntfile.js'], - tasks: ['eslint'] - }, - test: { - files: ['test/**/*.js'], - tasks: ['test'] - }, - all: { - files: ['Gruntfile.js', 'src/**/*.js', 'src/**/*.html', 'styles/**/*.css', '**/*.less'], - tasks: ['build'], - options: { - livereload: 35722 - } - } - } - }); - - grunt.registerTask('shipcss', function() { - if (sassBuild) { - grunt.task.run('copy:sassBuild'); - } - }); - - grunt.registerTask('copymain', ['copy:docdata', 'copy:fa', 'copy:img', 'copy:distimg', 'copy:distless', 'copy:distlessDependencies', 'copy:distsass']); - - // You can specify which modules to build as arguments of the build task. - grunt.registerTask('build', 'Create bootstrap build files', function () { - var concatSrc = []; - - if (this.args.length) { - this.args.forEach(function (file) { - if (grunt.file.exists('./src/' + file)) { - grunt.log.ok('Adding ' + file + ' to the build queue.'); - concatSrc.push('src/' + file + '/*.js'); - } else { - grunt.fail.warn('Unable to build module \'' + file + '\'. The module doesn\'t exist.'); - } - }); - - } else { - concatSrc = 'src/**/*.js'; - } - - grunt.task.run([ - 'clean', - 'lint', - 'test', - 'ngtemplates', - 'concat', - 'ngAnnotate', - 'uglify:build', - 'less', - 'lessToSass', - 'sass', - 'shipcss', - 'cssmin', - 'copymain', - 'string-replace', - 'uidocs-generator', - 'clean:templates']); - }); - - // Runs all the tasks of build with the exception of tests - grunt.registerTask('deploy', 'Prepares the project for deployment. Does not run unit tests', function () { - var concatSrc = 'src/**/*.js'; - grunt.task.run(['clean', 'lint', 'ngtemplates', 'concat', 'ngAnnotate', 'uglify:build', 'less', 'cssmin', 'copymain', 'string-replace', 'uidocs-generator', 'clean:templates']); - }); - - grunt.registerTask('default', ['build']); - grunt.registerTask('uidocs:view', ['build', 'connect:docs', 'watch']); - grunt.registerTask('lint', ['eslint', 'htmlhint']); - grunt.registerTask('test', ['karma', 'coveralls']); - grunt.registerTask('check', ['lint', 'test']); - grunt.registerTask('help', ['availabletasks']); - grunt.registerTask('serve', ['uidocs:view']); - grunt.registerTask('uidocs:publish', ['remove:published', 'copy:publish']); - - } - - init({}); - -}; diff --git a/LICENSE.txt b/LICENSE.txt deleted file mode 100644 index 8d9091a9e..000000000 --- a/LICENSE.txt +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2019 Red Hat, Inc. - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/README.md b/README.md deleted file mode 100644 index 1902edba3..000000000 --- a/README.md +++ /dev/null @@ -1,335 +0,0 @@ -[![Build Status](https://travis-ci.org/patternfly/angular-patternfly.svg?branch=master)](https://travis-ci.org/patternfly/angular-patternfly) -[![Dependency Status](https://gemnasium.com/badges/github.com/patternfly/angular-patternfly.svg)](https://gemnasium.com/github.com/patternfly/angular-patternfly) -[![Code Climate](https://codeclimate.com/github/patternfly/angular-patternfly/badges/gpa.svg)](https://codeclimate.com/github/patternfly/angular-patternfly) -[![NSP Status](https://nodesecurity.io/orgs/angular-patternfly/projects/690b94c3-4f36-4208-887d-fdb5f22f65fc/badge)](https://nodesecurity.io/orgs/angular-patternfly/projects/690b94c3-4f36-4208-887d-fdb5f22f65fc) -[![Join the chat at https://gitter.im/patternfly/angular-patternfly](https://badges.gitter.im/patternfly/angular-patternfly.svg)](https://gitter.im/patternfly/angular-patternfly?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) -[![Coverage Status](https://coveralls.io/repos/github/patternfly/angular-patternfly/badge.svg)](https://coveralls.io/github/patternfly/angular-patternfly) - -# AngularJS components for [PatternFly](https://www.patternfly.org) - -This project will provide a set of common AngularJS components for use with the PatternFly reference implementation. - -* Web site: https://www.patternfly.org -* API Docs: http://www.patternfly.org/angular-patternfly/#/api -* Build Status: https://travis-ci.org/patternfly/angular-patternfly.svg?branch=master - -## Getting started - -You have to install required software before you're able to use grunt: - -* Install Node.js - Find more information on [Node.js](http://nodejs.org/) - - Angular Patternfly stays up to date with the Node LTS [Release Schedule](https://github.com/nodejs/LTS#lts_schedule). If you're using Angular Patternfly downstream, we suggest the use of an actively supported version of Node/NPM, although prior versions of Node may work. - -* Install npm - If npm is not already installed with Node.js, you have to install it manually. Find more information on [NPM](https://www.npmjs.org/) - -* Install Grunt globally - Find more information on [Grunt](http://gruntjs.com/) - ```shell - $ npm install -g grunt-cli - ``` - -* Install npm dependencies with: - ```shell - $ npm install - ``` - -You should have your environment ready now. - -Angular-PatternFly can now be built with: -```shell -$ npm run build -``` - -To see all the grunt tasks that are available: -```shell -$ npm run help -``` - -### Using Angular-PatternFly In Your Application - -Note: - -1. Add Angular-PatternFly as dependencies for your project and you'll receive all the libraries you'll need: - ```shell - $ npm install angular-patternfly --save - ``` -2. Add the core Patternfly CSS and script includes to your HTML file(s): - - Please see: https://github.com/patternfly/patternfly/blob/master/QUICKSTART.md - - Alternatively, the minimum you will need: - - - - - - - - - - -3. Add the following CSS include to your HTML file(s): - - ```html - - - ``` -4. Add the following script includes to your HTML file(s), adjusting where necessary to pull in only what you need: - - ```html - - - - - - - - - - - - - - - - - - - - - - - ``` - -5. (optional) The 'patternfly.charts' module is not a dependency in the default angular 'patternfly' module. - In order to use patternfly charts you must add it as a dependency in your application: - - ```javascript - my-app.module.js: - - angular.module('myApp', [ - 'patternfly', - 'patternfly.charts' - ]); - ``` - - And script includes to your HTML file: - ```html - - - - ```` - -6. (optional) The 'patternfly.table' module is not a dependency in the default angular 'patternfly' module. - In order to use pfTableView, you must add 'patternfly.table' as a dependency in your application: - - ```javascript - my-app.module.js: - - angular.module('myApp', [ - 'patternfly', - 'patternfly.table' - ]); - ``` - - Add the npm dependency: - ```shell - $ npm install angularjs-datatables --save - ``` - - Add the following CSS includes to your HTML file(s): - - - ```html - - - ``` - Add the following Javascript includes to your HTML file(s): - - ```html - - - - - - ``` -7. (optional) The 'patternfly.canvas' module is not a dependency in the default angular 'patternfly' module. - In order to use pfCanvasEditor or pfCanvas, you must add 'patternfly.canvas' as a dependency in your application: - - ```javascript - my-app.module.js: - - angular.module('myApp', [ - 'patternfly', - 'patternfly.canvas' - ]); - ``` - - Add the npm dependencies: - ```shell - $ npm install jquery-ui-dist --save - $ npm install angular-dragdrop --save - $ npm install angular-svg-base-fix --save - ``` - - Add the following Javascript includes to your HTML file(s): - - ```html - - - - - - - - ``` - - Also, the canvas background grid image is located in 'node_modules/angular-patternfly/dist/imgs/canvas-dot-grid.png' - please copy this image to your application's main images directory and reference it by overridding the '.canvas' css - class: - - ```html - - ``` - -#### Less to Sass Conversion - -During the build process Less files are converted to Sass files in `/dist/sass`. Then the Sass files are compiled into `/dist/sass/angular-patternfly.css`. If you would like to copy the Sass generated css into the main `/dist/styles` directory, execute: - -``` -grunt build --sass -``` - -This task will copy `/dist/sass/angular-patternfly.css` to `/dist/styles/angular-patternfly.css`. Then the build process will minimize the css in `/dist/styles`. - -The Less to Sass Conversion step will be accomplished and managed as a part of any Pull Request which includes Less file changes. Although contributors may want to build and test their style changes with Sass before submitting a Pull Request, this step should always be tested and validated by reviewers before a style change is merged and released. If a contributor is having issues with Sass conversion that they cannot resolve, Pull Request reviewers will need to ensure that the Sass conversion step is successfully accomplished, tested, and included in the Pull Request before it is approved and merged. - -For more detailed information, please read [PatternFly Less to Sass Conversion](https://github.com/patternfly/patternfly#less-to-sass-conversion) - -*Note:* When a Less file is added/deleted/renamed it needs to be updated in the main Less import file `/styles/angular-patternfly.less` and the main Sass import file `styles/_angular-patternfly.scss`. - -### Using with Webpack - -In order to use Angular-Patternfly in a Webpack-bundled application there are some things you need to keep in mind: - -#### Create an alias for the jQuery module (if using JQuery dependency) - -In order to let Webpack find the correct jQuery module when assembling all the dependencies you need to create an alias for it in the webpack.conf.js file: -``` -... -resolve: { - alias: { - "jquery": "patternfly/node_modules/jquery" - } -} -... -``` - -Additionally, you have to use the `webpack.ProvidePlugin` so the $ and the jQuery variables are added to the `window` object, making them available to the other modules (Patternfly included): -``` -... -plugins: [ - new webpack.ProvidePlugin({ - $: "jquery", - jQuery: "jquery", - "window.jQuery": "jquery", - "window.jquery": "jquery" - }) -] -... -``` - -## API documentation - -The API documentation can be built with: -```shell -$ npm run uidocs -``` - -If you're interested in reading the docs right away, you can use special target, which will start a web server: -```shell -$ npm run uidocs:view -``` - -After executing this tasks you'll be able to access the documentation at [http://localhost:8000/](http://localhost:8000/). If a different port is desired, it may be specified on as an option: -```shell -$ npm run uidocs:view -- --port=8002 -``` - -## Git Commit Guidelines - -PatternFly uses a semantic release process to automate npm and bower package publishing, based on the following commit message format. - -Each commit message consists of a **header**, a **body** and a **footer**. The header has a special -format that includes a **type**, a **scope** and a **subject** ([full explanation](https://github.com/stevemao/conventional-changelog-angular/blob/master/convention.md)): - -``` -(): - - - -