Skip to content

Commit

Permalink
Merge pull request #360 from tempusdominus/conflict-merge
Browse files Browse the repository at this point in the history
Conflict merge
  • Loading branch information
Eonasdan authored Nov 20, 2020
2 parents 13f979d + ee368d1 commit 8e64d3e
Show file tree
Hide file tree
Showing 45 changed files with 28,583 additions and 15,804 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ site
/index.html
/test.html
/npm-debug.log
private_local_dir/**
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
**
35 changes: 15 additions & 20 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,38 +1,33 @@
Submitting Issues
=================

If you are submitting a bug, please test and/or fork [this jsfiddle](https://jsfiddle.net/Eonasdan/bdxss6m8/) demonstrating the issue. Code issues and fringe case bugs that do not include a jsfiddle (or similar) will be closed.
If you are submitting a bug, please test and/or fork [this JSFiddle](https://jsfiddle.net/nmocbjLf/1/) demonstrating the issue.
In your Pull Request (PR), describe the use case and provide a link to your forked JSFiddle and possibly provide a code example in the PR itself.

Issues that are submitted without a description (title only) will be closed with no further explanation.

Contributing code
=================

To contribute, fork the library and install grunt and dependencies. You need [node](http://nodejs.org/); use [nvm](https://github.com/creationix/nvm) or [nenv](https://github.com/ryuone/nenv) to install it.
PRs are welcome.

**Working on your first Pull Request?** You can learn how from this _free_ series [How to Contribute to an Open Source Project on GitHub](https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github).

To contribute, fork the library and install dependencies. You will need [node](http://nodejs.org/).
You can use [nvm](https://github.com/nvm-sh/nvm) or [nenv](https://github.com/ryuone/nenv) to install it.

Then, run the following commands:

```bash
git clone https://github.com/tempusdominus/bootstrap-4.git
cd bootstrap-4
git clone https://github.com/tonix-tuft/tempusdominus-bootstrap.git
cd tempusdominus-bootstrap
npm install -g grunt-cli
npm install
git checkout development # all patches against development branch, please!
grunt # this runs tests and jshint
npm run watch
```

Very important notes
====================

* **Pull requests to the `master` branch will be closed.** Please submit all pull requests to the `development` branch.
* **Do not include the minified files in your pull request.** Don't worry, we'll build them when we cut a release.
* Pull requests that do not include a description (title only) and the following will be closed:
* What the change does
* A use case (for new features or enhancements)

Grunt tasks
===========

We use Grunt for managing the build. Here are some useful Grunt tasks:

* `grunt` The default task lints the code and runs the tests. You should make sure you do this before submitting a PR.
* `grunt build` Compiles the less stylesheet and minifies the javascript source in build directory.
* `grunt build:travis` Compliles and runs the jasmine/travis tests. **All PR's MUST pass tests in place**
* **Please submit your pull requests to a new branch** (you may call it like you want, just choose a name that describes your feature/bugfix).
* **You don't have to include the minified files in your pull request** (by running `npm run build-all`). Don't worry, we'll build them when we bump a new version.
62 changes: 45 additions & 17 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
const sass = require('node-sass'), tildeImporter = require('grunt-sass-tilde-importer');

module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
banner: '/*@preserve\n' +
banner: '/*!@preserve\n' +
' * Tempus Dominus Bootstrap4 v<%= pkg.version %> (<%= pkg.homepage %>)\n' +
' * Copyright 2016-<%= grunt.template.today("yyyy") %> <%= pkg.author %>\n' +
' * Copyright 2016-<%= grunt.template.today("yyyy") %> <%= pkg.author %> and contributors\n' +
' * Licensed under MIT (https://github.com/tempusdominus/bootstrap-3/blob/master/LICENSE)\n' +
' */\n',
jqueryCheck: 'if (typeof jQuery === \'undefined\') {\n' +
Expand Down Expand Up @@ -36,10 +34,10 @@ module.exports = function (grunt) {
dead_code: false // eslint-disable-line
},
output: {
ascii_only: true // eslint-disable-line
ascii_only: true, // eslint-disable-line
comments: 'some'
},
report: 'min',
preserveComments: 'some'
report: 'min'
}
},
eslint: {
Expand All @@ -63,7 +61,7 @@ module.exports = function (grunt) {
compact: false,
'presets': [
[
'es2015',
'@babel/preset-env',
{
'modules': false,
'loose': true
Expand All @@ -88,28 +86,24 @@ module.exports = function (grunt) {
},
bootstrap: {
src: [
'node_modules/tempusdominus-core/src/js/tempusdominus-core.js',
'node_modules/tempusdominus/src/js/tempusdominus.js',
'src/js/<%= pkg.name %>.js'
],
dest: 'build/js/<%= pkg.name %>.js'
}
},
sass: {
'dart-sass': {
production: {
options: {
cleancss: true,
compress: true,
implementation: sass,
importer: tildeImporter
outputStyle: 'compressed'
},
files: {
'build/css/<%= pkg.name %>.min.css': 'src/sass/<%= pkg.name %>-build.scss'
}
},
development: {
options: {
importer: tildeImporter,
implementation: sass

},
files: {
'build/css/<%= pkg.name %>.css': 'src/sass/<%= pkg.name %>-build.scss'
Expand Down Expand Up @@ -148,11 +142,43 @@ module.exports = function (grunt) {
clean: true
}
}
},
postcss: {
options: {
map: false,
processors: [
require('autoprefixer')({
// grid: true
})
]
},
dist: {
src: 'build/css/<%= pkg.name %>.css'
}
},
cssmin: {
options: {
specialComments: 'all'
},
target: {
files: [{
expand: true,
cwd: 'build/css',
src: ['*.css', '!*.min.css'],
dest: 'build/css',
ext: '.min.css'
}]
}
}
});

grunt.loadTasks('tasks');
grunt.loadNpmTasks('grunt-mkdocs');
grunt.loadNpmTasks('grunt-dart-sass');
grunt.loadNpmTasks('grunt-postcss')
grunt.loadNpmTasks('grunt-contrib-cssmin')
grunt.loadNpmTasks('grunt-contrib-uglify')
grunt.loadNpmTasks('grunt-contrib-watch')

require('load-grunt-tasks')(grunt);
grunt.registerTask('default', 'build:js');
Expand All @@ -163,9 +189,11 @@ module.exports = function (grunt) {
]);

// Task to be run when building
grunt.registerTask('build', ['build:js', 'build:style']);

grunt.registerTask('build:js', ['babel:dev', 'concat', 'eslint', 'babel:dist', 'stamp:bootstrap', 'uglify', 'copy']);

grunt.registerTask('build:style', ['sass', 'stamp:css', 'copy']);
grunt.registerTask('build:style', ['dart-sass', 'stamp:css', 'postcss', 'cssmin', 'copy']);

grunt.registerTask('copy', 'Generate docs', function () {
grunt.file.copy('build/js/tempusdominus-bootstrap-4.js', 'src/docs/theme/js/tempusdominus-bootstrap-4.js');
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
# tempusdominus-bootstrap

This package is a fork of the original [tempusdominus/bootstrap-4](https://github.com/tempusdominus/bootstrap-4) repo.

This fork includes bugfixes, new features, and comes with updated NPM packages ([JSFiddle](https://jsfiddle.net/nmocbjLf/1/)).

The original README.md follows below this paragraph.

# Tempus Dominus Bootstrap 4
![GitHub version](https://badge.fury.io/gh/tempusdominus%2Fbootstrap-3-datetimepicker.png)

Expand Down
Loading

0 comments on commit 8e64d3e

Please sign in to comment.