-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lots of features #17
base: master
Are you sure you want to change the base?
Lots of features #17
Commits on Aug 7, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 204280b - Browse repository at this point
Copy the full SHA 204280bView commit details -
Configuration menu - View commit details
-
Copy full SHA for d5caa21 - Browse repository at this point
Copy the full SHA d5caa21View commit details
Commits on Aug 8, 2019
-
🐛 Fix bug where frame is undefined
setFrames() now sets this.currentFrameIndex = 0; Logs are a thing now. Use: spinnies.addLog(log); to add a log. Then just use spinnies.log() or spinnies.getLogs();
Configuration menu - View commit details
-
Copy full SHA for 8cbe1a6 - Browse repository at this point
Copy the full SHA 8cbe1a6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1b9b5e8 - Browse repository at this point
Copy the full SHA 1b9b5e8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2b51b29 - Browse repository at this point
Copy the full SHA 2b51b29View commit details
Commits on Aug 9, 2019
-
🎆 Word-wrap is used for multiple lines
wordwrapjs library is used to break text. Each line after the first line get's indented using the prefixLength.
Configuration menu - View commit details
-
Copy full SHA for 4ddc50e - Browse repository at this point
Copy the full SHA 4ddc50eView commit details -
🎐 Add support for the 'indent' option
breakText, indentText and getLinesLength were modified to handle the indent option. Each line in a mutli-line text spinner will be indented as well. See: jbcarpanelli#14 rap2hpoutre/taskz#3 jbcarpanelli#15
Configuration menu - View commit details
-
Copy full SHA for 4df6cd4 - Browse repository at this point
Copy the full SHA 4df6cd4View commit details -
Configuration menu - View commit details
-
Copy full SHA for af8b280 - Browse repository at this point
Copy the full SHA af8b280View commit details -
🪲 Fix bug where spinner would change status to 'spinning'
If you tried to update a spinner using spinners.update(), and the status of the spinner was anything but spinning (succeed, fail, stopped, unspinnable), the spinner would automatically be thrown into spinning mode. Reason is: `status = status || 'spinning';` Will make the status default to spinning if not specified.
Configuration menu - View commit details
-
Copy full SHA for 4e16b50 - Browse repository at this point
Copy the full SHA 4e16b50View commit details
Commits on Aug 10, 2019
-
❇️ Each spinner now has it's own instance
Code is now cleaner and easier to work on. It's now clear that the spinners instance takes care of loops, rendering, etc.. And each spinner takes care of what to render. Also this gives us to ability to do stuff like: const spinnies = new Spinnies(); const spinner1 = spinnies.add('spinner-1', { text: 'Hello! I am the initial text', color: 'green' }); // some code spinnies.fail('spinner-1'); // same as spinnies.get('spinner-1').fail(); // same as spinner1.fail();
Configuration menu - View commit details
-
Copy full SHA for f1cdc2b - Browse repository at this point
Copy the full SHA f1cdc2bView commit details -
spinners.childFunction(spinnerName, action, ...args) - will call a function on a child spinner. childFunction will also verify spinnerName is a string and the spinner was initialized. Before: succeed(name, options = {}) { const spinner = this.get(name); spinner.succeed(options); return spinner; } After: succeed(name, options = {}) { return this.childFuction(name, 'succeed', options); }
Configuration menu - View commit details
-
Copy full SHA for 78b6bff - Browse repository at this point
Copy the full SHA 78b6bffView commit details -
`examples/demo.js` - Uses the syntax: spinners.update(spinnerName, options); `examples/demo-using-get` Uses the syntax: spinners.get(spinnerName).update(options);
Configuration menu - View commit details
-
Copy full SHA for 09e5736 - Browse repository at this point
Copy the full SHA 09e5736View commit details -
Fix the tests that were broken by giving each spinner it's own instance. Must of the fixes involves changing: `spinner.optionNameHereLikeStatus` To: `spinner.options.optionNameHereLikeStatus` Since function now return the spinner's instance and not the spinner's options.
Configuration menu - View commit details
-
Copy full SHA for b32cdb0 - Browse repository at this point
Copy the full SHA b32cdb0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 649f077 - Browse repository at this point
Copy the full SHA 649f077View commit details
Commits on Aug 11, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 2bf3c25 - Browse repository at this point
Copy the full SHA 2bf3c25View commit details -
Configuration menu - View commit details
-
Copy full SHA for 135ea79 - Browse repository at this point
Copy the full SHA 135ea79View commit details -
Configuration menu - View commit details
-
Copy full SHA for 21783d3 - Browse repository at this point
Copy the full SHA 21783d3View commit details -
Configuration menu - View commit details
-
Copy full SHA for cf83a55 - Browse repository at this point
Copy the full SHA cf83a55View commit details -
🎊 Rename setStatus to configureStatus
setStatus might make the user think he is setting the spinner's status and not adding/modifying the status. Note: statuses are still not implemented in any way shape or form.
Configuration menu - View commit details
-
Copy full SHA for ced70d7 - Browse repository at this point
Copy the full SHA ced70d7View commit details -
🍓 Add rawRender option for stasus
Better support for CI and static render. Not implementetd yet.
Configuration menu - View commit details
-
Copy full SHA for 342295d - Browse repository at this point
Copy the full SHA 342295dView commit details
Commits on Aug 12, 2019
-
... To share and update statuses with all spinners and the main spinners instance.
Configuration menu - View commit details
-
Copy full SHA for db45b13 - Browse repository at this point
Copy the full SHA db45b13View commit details
Commits on Aug 13, 2019
-
Some parts of the docs are plans for the future (next commit), like spinner.status();
Configuration menu - View commit details
-
Copy full SHA for 97cee6a - Browse repository at this point
Copy the full SHA 97cee6aView commit details -
Create statusOptionsFromNormalUpdate and statusOverrides.
Configuration menu - View commit details
-
Copy full SHA for 75c4b4a - Browse repository at this point
Copy the full SHA 75c4b4aView commit details -
Write tests for purgeStatusOptions and statusOptionsFromNormalUpdate. Fix error with statusOptionsFromNormalUpdate, where `color` is undefined.
Configuration menu - View commit details
-
Copy full SHA for 58646e6 - Browse repository at this point
Copy the full SHA 58646e6View commit details -
Write tests for StatusRegistry. Fix bug with purgeStatusOptions. isStatic and noSpaceAfterPrefix would default to false when existing status would update.
Configuration menu - View commit details
-
Copy full SHA for 6c9f6f0 - Browse repository at this point
Copy the full SHA 6c9f6f0View commit details -
Create `status` function. If status is undefined or not a string the status will not be modified... TODO: should this throw an error? options now get passed to statusOptionsFromNormalUpdate, on update.
Configuration menu - View commit details
-
Copy full SHA for 7e2d799 - Browse repository at this point
Copy the full SHA 7e2d799View commit details
Commits on Aug 15, 2019
-
Write tests that test spinner modify functions with spinners.get('name'). Fix README.md indent. Fix statusOptionsFromNormalUpdate, it now sets the textColor option for fail and succeed statuses. statusOptionsFromNormalUpdate will run before the spinner options were purged, in spinner.update(). Which is why it will also check types. It fixes the issue where failPrefix and succeedPrefix options will be purged and not apply for the statusOverride. Fix the tests for statusOptionsFromNormalUpdate, to match the changes to statusOptionsFromNormalUpdate.
Configuration menu - View commit details
-
Copy full SHA for aa51e0e - Browse repository at this point
Copy the full SHA aa51e0eView commit details -
✅ Fix tests and EOL issues on windows
Tests for purgeSpinnersOptions will now check against the platformDefaultSpinner instead of defaulting to dots. This fixed the tests for platforms that don't support unicode. In everyplace a '\n' was used it was replaced with os.EOL, fixes tests on windows + prevent future problems.
Configuration menu - View commit details
-
Copy full SHA for c5dd46a - Browse repository at this point
Copy the full SHA c5dd46aView commit details -
🌙 Add tests for spinnies.status()
Using behaviours.test.js-expectToBehaveLikeAStatusChange to easily test for status changes.
Configuration menu - View commit details
-
Copy full SHA for 7063d74 - Browse repository at this point
Copy the full SHA 7063d74View commit details
Commits on Aug 16, 2019
-
Configuration menu - View commit details
-
Copy full SHA for f69cc53 - Browse repository at this point
Copy the full SHA f69cc53View commit details -
Configuration menu - View commit details
-
Copy full SHA for e2775ba - Browse repository at this point
Copy the full SHA e2775baView commit details
Commits on Aug 17, 2019
-
Create the rawRender method on the spinnie class. It will try to get a rawRender function from the current status and default to rendering the prefix with the text. rawRender on the status options should take care of the coloring. While everything else like indent and breaking text will be applied by the spinnie.rawRender method. Status option overrides will now apply on creation and not only when a spinner is updated. update statusOptionsFromNormalUpdate to update based on the spinnerColor option. prefixColor and spinnerColor will default to cyan instead of greenBright. Note: setRawStreamOutput is not the final form of CI/not-spinning rendering.
Configuration menu - View commit details
-
Copy full SHA for e719068 - Browse repository at this point
Copy the full SHA e719068View commit details -
Configuration menu - View commit details
-
Copy full SHA for d75eb35 - Browse repository at this point
Copy the full SHA d75eb35View commit details
Commits on Aug 21, 2019
-
Status overrides will merge with previous status overrides. Write tests for this. FIx the tests that were broken by the changes to statusOptionsFromNormalUpdate in #e719068
Configuration menu - View commit details
-
Copy full SHA for 755d2ec - Browse repository at this point
Copy the full SHA 755d2ecView commit details -
Configuration menu - View commit details
-
Copy full SHA for be81daf - Browse repository at this point
Copy the full SHA be81dafView commit details -
Configuration menu - View commit details
-
Copy full SHA for 12bd7ac - Browse repository at this point
Copy the full SHA 12bd7acView commit details -
👾 Add a space after each
if
statementConsistency is key. (should we add prettier?)
Configuration menu - View commit details
-
Copy full SHA for 29fc274 - Browse repository at this point
Copy the full SHA 29fc274View commit details -
⏪ spinnies.remove() will check that 'name' is a string
It will throw an error if it's not.
Configuration menu - View commit details
-
Copy full SHA for 1f2f0f6 - Browse repository at this point
Copy the full SHA 1f2f0f6View commit details -
🚗 Write tests for the 'remove' method
The tests will make sure the spinner is deleted from the spinners object and also that we don't listen to events from that spinner anymore. Incase we still have a refrence to a spinner after we deleted it and we call spinner.update() for example we shouldn't reload everything... The listeners part is testedd using the 'sinon' library and sinon.spy(); (should we add more spy and mock tests using sinon?)
Configuration menu - View commit details
-
Copy full SHA for aea3295 - Browse repository at this point
Copy the full SHA aea3295View commit details
Commits on Aug 25, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 955ebf5 - Browse repository at this point
Copy the full SHA 955ebf5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4aac332 - Browse repository at this point
Copy the full SHA 4aac332View commit details -
❗ Use 'signal-exit' instead of binding sigint
This way we bind all possible exit events including process.exit(). cli-cursor will automatically show the cursor so there is no need to manually do it. When the spinnies instance is done spinning it will unbind the exit event.
Configuration menu - View commit details
-
Copy full SHA for a634f33 - Browse repository at this point
Copy the full SHA a634f33View commit details -
A regex to match all line breaks is used instead of os.EOL when splitting strings.
Configuration menu - View commit details
-
Copy full SHA for 4f56272 - Browse repository at this point
Copy the full SHA 4f56272View commit details -
Configuration menu - View commit details
-
Copy full SHA for 390d1c9 - Browse repository at this point
Copy the full SHA 390d1c9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5f72cc0 - Browse repository at this point
Copy the full SHA 5f72cc0View commit details -
Configuration menu - View commit details
-
Copy full SHA for fa37d7f - Browse repository at this point
Copy the full SHA fa37d7fView commit details -
🐶 Implement custom statuses!!!! (Finally)
Yay :D Also fix a typo where 'grey' was used instead of 'gray'.
Configuration menu - View commit details
-
Copy full SHA for 5978e6e - Browse repository at this point
Copy the full SHA 5978e6eView commit details -
Configuration menu - View commit details
-
Copy full SHA for b9bd15d - Browse repository at this point
Copy the full SHA b9bd15dView commit details -
aliasChildMethod is used instead of manually setting each function. spinnies.get() will now check that that spinner exists. #remove tests were changed to work with the changes to spinnies.get()
Configuration menu - View commit details
-
Copy full SHA for ba0b213 - Browse repository at this point
Copy the full SHA ba0b213View commit details -
Fix stopAll() tests that were broken by custom statuses
The tests no longer check if the color option was changed since it doesn't modify it. If a status that doesn't exists is passed to stopAll() it will default to 'stopped' instead of 'spinning'.
Configuration menu - View commit details
-
Copy full SHA for faf428d - Browse repository at this point
Copy the full SHA faf428dView commit details
Commits on Aug 26, 2019
-
🐺 Implement the use of spinner.statusName()
Hooray! So how is this done? StatusRegistry now extends EventEmitter and emits an event name 'statusAdded' whenever you add a status. The main spinnies instance will listen to that event and loop the spinners and use aliasStatusAsMethod to alias that status. It will also use aliasChildMethod to alias spinnies.statusName('spinnerName') to spinnies.get('spinnerName').statusName(). Each spinner will use aliasStatusAsMethod on initialization for each of the statuses (and aliases) in the statusRegistry. TODO: write tests
Configuration menu - View commit details
-
Copy full SHA for d11f07a - Browse repository at this point
Copy the full SHA d11f07aView commit details -
Since spinnie.update() checks if you only update the status and if you do it uses the spinnie.status() method it doesn't matter if you use method 2.
Configuration menu - View commit details
-
Copy full SHA for d399883 - Browse repository at this point
Copy the full SHA d399883View commit details
Commits on Aug 27, 2019
-
📌 Create purgeOptions.js to purge options
Purging functions like purgeSpinnersOptions, purgeSpinnerOptions and purgeStatusOptions should use this. This provides better readability and much easier to add options. It will delete unknown props and make sure all props are valid using a set of rules passed to it. Example: const purged = purgeOptions({ status: type('string'), color: isValidColor, light: oneOf(['green', 'yellow', 'red']), custom: (value) => returnTrueToKeepAndFalseToRemove(value), numberOrString: some([ type('string'), type('number') ]) });
Configuration menu - View commit details
-
Copy full SHA for 15b6d1f - Browse repository at this point
Copy the full SHA 15b6d1fView commit details -
Also fix a bug where purgeSpinnerOptions will purge custom statuses. Fix some tests that were broken by custom statuses and only noticed when VALID_STATUSES was remove.
Configuration menu - View commit details
-
Copy full SHA for 52b2967 - Browse repository at this point
Copy the full SHA 52b2967View commit details -
Configuration menu - View commit details
-
Copy full SHA for edc07e7 - Browse repository at this point
Copy the full SHA edc07e7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 64bf24d - Browse repository at this point
Copy the full SHA 64bf24dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3a284d0 - Browse repository at this point
Copy the full SHA 3a284d0View commit details -
Configuration menu - View commit details
-
Copy full SHA for 245b70b - Browse repository at this point
Copy the full SHA 245b70bView commit details -
Create tests for the isStatic and noSpaceAfterPrefix options in purgeStatusOptions.
Configuration menu - View commit details
-
Copy full SHA for 7533a34 - Browse repository at this point
Copy the full SHA 7533a34View commit details
Commits on Aug 28, 2019
-
✅ Write tests for assertion helpers
I think it's a bit overkill but what ever.
Configuration menu - View commit details
-
Copy full SHA for 6f8759f - Browse repository at this point
Copy the full SHA 6f8759fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 8b966b5 - Browse repository at this point
Copy the full SHA 8b966b5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 86fef3f - Browse repository at this point
Copy the full SHA 86fef3fView commit details -
updateSpinnerState is passed a spinner name when a spinner is updated then instead of spitting out all of the spinners it will only print this one.
Configuration menu - View commit details
-
Copy full SHA for 7871f83 - Browse repository at this point
Copy the full SHA 7871f83View commit details -
README says it all: - **isDone** - `booolean`: By default statuses are treated as 'done' if the `isStatic` option is `true`. For example statuses like success, fail and stopped are treated as done, while the *spinning* is not treated as 'done'. Whenever a status of a spinner is treated as 'done' spinnies will know to complete that spinner and to stop spinning when ever all spinners are done. By default any *static* status with `isStatic` set to true will also be treated as 'done'. This option is rarely ever used since the default behavior suits most statuses. This is good for example if we want to create a **pending** status. The pending status can be good for tasks that will be executed in the future but are not running yet. We don't want spinnies the think a spinner with the **pending** status is 'done' but we also don't want a spinner with a **pending** status to spin.
Configuration menu - View commit details
-
Copy full SHA for 9c7fc1a - Browse repository at this point
Copy the full SHA 9c7fc1aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 911f00a - Browse repository at this point
Copy the full SHA 911f00aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4101d12 - Browse repository at this point
Copy the full SHA 4101d12View commit details -
Configuration menu - View commit details
-
Copy full SHA for ec5867e - Browse repository at this point
Copy the full SHA ec5867eView commit details
Commits on Aug 29, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 3d087c3 - Browse repository at this point
Copy the full SHA 3d087c3View commit details -
Configuration menu - View commit details
-
Copy full SHA for dae6bd5 - Browse repository at this point
Copy the full SHA dae6bd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 63efe63 - Browse repository at this point
Copy the full SHA 63efe63View commit details
Commits on Aug 30, 2019
-
⚠️ ℹ️ Create warn and info statusesSupport for using `warnPrefix`, `warnColor`, `infoPrefix` and `infoColor` options.
Configuration menu - View commit details
-
Copy full SHA for d755ea9 - Browse repository at this point
Copy the full SHA d755ea9View commit details -
Configuration menu - View commit details
-
Copy full SHA for ca92d98 - Browse repository at this point
Copy the full SHA ca92d98View commit details -
Configuration menu - View commit details
-
Copy full SHA for a0e9042 - Browse repository at this point
Copy the full SHA a0e9042View commit details -
Configuration menu - View commit details
-
Copy full SHA for a893d5b - Browse repository at this point
Copy the full SHA a893d5bView commit details -
Hooray! Use spinner.hidden(bool) to set hidden to true or false. Also use spinner.hide() and spinner.show() for convenience. Note: ignore the demo for now, it just became a bit of a mess while testing features...
Configuration menu - View commit details
-
Copy full SHA for f436192 - Browse repository at this point
Copy the full SHA f436192View commit details
Commits on Aug 31, 2019
-
Add tests for the 'hidden' option, spinner.hidden(), spinner.hide() and spinner.show().
Configuration menu - View commit details
-
Copy full SHA for 7827cba - Browse repository at this point
Copy the full SHA 7827cbaView commit details -
Add the hidden option, hidden(), hide() and show() to README
Configuration menu - View commit details
-
Copy full SHA for fd39320 - Browse repository at this point
Copy the full SHA fd39320View commit details -
Explain how some methods can be called on the main spinnies instance and on the individual spinner instance.
Configuration menu - View commit details
-
Copy full SHA for 5a0a219 - Browse repository at this point
Copy the full SHA 5a0a219View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7253bb1 - Browse repository at this point
Copy the full SHA 7253bb1View commit details -
Configuration menu - View commit details
-
Copy full SHA for 607d893 - Browse repository at this point
Copy the full SHA 607d893View commit details -
Configuration menu - View commit details
-
Copy full SHA for 51312ce - Browse repository at this point
Copy the full SHA 51312ceView commit details -
Configuration menu - View commit details
-
Copy full SHA for eb5509c - Browse repository at this point
Copy the full SHA eb5509cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 66a78df - Browse repository at this point
Copy the full SHA 66a78dfView commit details -
Update the Installation section to include instructions for installing with yarn.
Configuration menu - View commit details
-
Copy full SHA for e5ba280 - Browse repository at this point
Copy the full SHA e5ba280View commit details -
Configuration menu - View commit details
-
Copy full SHA for f69cc03 - Browse repository at this point
Copy the full SHA f69cc03View commit details -
Demo shows all default statuses, Indented spinner, removing a spinner, multiline spinner and changing the spinner animation.
Configuration menu - View commit details
-
Copy full SHA for ce86bd4 - Browse repository at this point
Copy the full SHA ce86bd4View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2815120 - Browse repository at this point
Copy the full SHA 2815120View commit details -
Configuration menu - View commit details
-
Copy full SHA for cddb399 - Browse repository at this point
Copy the full SHA cddb399View commit details
Commits on Sep 1, 2019
-
The text method changes the text of a spinner. Demo.js now uses the text method.
Configuration menu - View commit details
-
Copy full SHA for 4dcc522 - Browse repository at this point
Copy the full SHA 4dcc522View commit details -
Configuration menu - View commit details
-
Copy full SHA for af12c21 - Browse repository at this point
Copy the full SHA af12c21View commit details -
Configuration menu - View commit details
-
Copy full SHA for b596e41 - Browse repository at this point
Copy the full SHA b596e41View commit details -
The indent method sets the indent of a spinner.
Configuration menu - View commit details
-
Copy full SHA for 4d85dd5 - Browse repository at this point
Copy the full SHA 4d85dd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6a2d7f8 - Browse repository at this point
Copy the full SHA 6a2d7f8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 544e185 - Browse repository at this point
Copy the full SHA 544e185View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7a9faba - Browse repository at this point
Copy the full SHA 7a9fabaView commit details -
Configuration menu - View commit details
-
Copy full SHA for 11b33b4 - Browse repository at this point
Copy the full SHA 11b33b4View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8098ecc - Browse repository at this point
Copy the full SHA 8098eccView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3f0775e - Browse repository at this point
Copy the full SHA 3f0775eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 167d383 - Browse repository at this point
Copy the full SHA 167d383View commit details -
Configuration menu - View commit details
-
Copy full SHA for 14ea00c - Browse repository at this point
Copy the full SHA 14ea00cView commit details -
Fix wordwrapjs link. Change emoji for stopped status
Configuration menu - View commit details
-
Copy full SHA for 9b3d538 - Browse repository at this point
Copy the full SHA 9b3d538View commit details -
Thanks to a code snippet taken from the 'ci-info' package. (Should spinnies use the 'ci-info' package directly?)
Configuration menu - View commit details
-
Copy full SHA for 0e50ebd - Browse repository at this point
Copy the full SHA 0e50ebdView commit details
Commits on Sep 2, 2019
-
Configuration menu - View commit details
-
Copy full SHA for 4f25d94 - Browse repository at this point
Copy the full SHA 4f25d94View commit details
Commits on Sep 4, 2019
-
🍴 breakText will force break if needed
It's better for a url/file path/super long word to break if it can't be wrapped instead of the entire cli program to break. That's what the break option in wordwrapjs is for.
Configuration menu - View commit details
-
Copy full SHA for 696fa73 - Browse repository at this point
Copy the full SHA 696fa73View commit details -
Pass a promise to 'bind'. If that promise resolves it will succeed the spinner with an optional success message. If that promise rejects it will fail the spinner with an optional error message. This is a very basic implementation of the bind method. It should be able to handle an observable and to format error messages if an error is passed.
Configuration menu - View commit details
-
Copy full SHA for 07df6e0 - Browse repository at this point
Copy the full SHA 07df6e0View commit details -
💯 A promise passed to 'bind' can now reject with an error
The error is formated and used as the spinner's text.
Configuration menu - View commit details
-
Copy full SHA for ac7cc6d - Browse repository at this point
Copy the full SHA ac7cc6dView commit details -
🌈 Colors like prefixColor, spinnerColor and textColor can now be false
To let the user color the text and prefix how they want. render and rawRender on the Spinnie instance were modified to check if the color exists and only if it is color the prefix. `false` was added to the list of valid colors.
Configuration menu - View commit details
-
Copy full SHA for 5132428 - Browse repository at this point
Copy the full SHA 5132428View commit details -
Configuration menu - View commit details
-
Copy full SHA for 423699d - Browse repository at this point
Copy the full SHA 423699dView commit details -
You can now pass an observable to 'bind'
subscriber.next() will update the spinner text. subscriber.complete() will succeed subscriber.error(err) will fail the spinner with an optional error.
Configuration menu - View commit details
-
Copy full SHA for d1f8f49 - Browse repository at this point
Copy the full SHA d1f8f49View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2cd3bc2 - Browse repository at this point
Copy the full SHA 2cd3bc2View commit details -
Create a test for #breakText passing a really long word and making sure it breaks that word.
Configuration menu - View commit details
-
Copy full SHA for 4e9ae9d - Browse repository at this point
Copy the full SHA 4e9ae9dView commit details -
Configuration menu - View commit details
-
Copy full SHA for dd0fbc5 - Browse repository at this point
Copy the full SHA dd0fbc5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3995d67 - Browse repository at this point
Copy the full SHA 3995d67View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8dbdf02 - Browse repository at this point
Copy the full SHA 8dbdf02View commit details -
Configuration menu - View commit details
-
Copy full SHA for ca88f39 - Browse repository at this point
Copy the full SHA ca88f39View commit details
Commits on Sep 12, 2019
-
📶 Use this.stream instead of process.stderr
breakText now takes a stream as the last argument. stream is also passed to each spinner child so it can correctly break text.
Configuration menu - View commit details
-
Copy full SHA for 47a4ae3 - Browse repository at this point
Copy the full SHA 47a4ae3View commit details -
Pass custom stream to spinnies. For examples you could pass `process.stdout`.
Configuration menu - View commit details
-
Copy full SHA for 872973b - Browse repository at this point
Copy the full SHA 872973bView commit details -
Configuration menu - View commit details
-
Copy full SHA for f2fd208 - Browse repository at this point
Copy the full SHA f2fd208View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9ec3db9 - Browse repository at this point
Copy the full SHA 9ec3db9View commit details -
🔗 LinesLength is checked after the prefix is added
This makes it less confusing than it was before. Instead of measuring the text without the prefix and adding the prefix length to the first line length getLinesLengh will simply map each line to it's length.
Configuration menu - View commit details
-
Copy full SHA for d457d7f - Browse repository at this point
Copy the full SHA d457d7fView commit details -
🍂 LinesLength is measured in setStreamOutput
Since the `render` method no longer needs to measure the linesLength before adding the prefix it makes sense for setStreamOutput to do it. That way `render` only renders the line.
Configuration menu - View commit details
-
Copy full SHA for b9941bd - Browse repository at this point
Copy the full SHA b9941bdView commit details -
The tests for the breakText util were broken by the recent changes that required a stream to be passed to `breakText`.
Configuration menu - View commit details
-
Copy full SHA for bbd8959 - Browse repository at this point
Copy the full SHA bbd8959View commit details -
🔒 Remove the docs for
log
andgetLogs
Since no debug logs are logged by the spinnies instance (atm) it seems pointless to mention those methods in the readme. Logs are still very useful for debugging spinnies when adding new features/modifying existing once.
Configuration menu - View commit details
-
Copy full SHA for bcb0666 - Browse repository at this point
Copy the full SHA bcb0666View commit details
Commits on Sep 28, 2020
-
Configuration menu - View commit details
-
Copy full SHA for f49129f - Browse repository at this point
Copy the full SHA f49129fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0c9a5d9 - Browse repository at this point
Copy the full SHA 0c9a5d9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 851db18 - Browse repository at this point
Copy the full SHA 851db18View commit details -
Configuration menu - View commit details
-
Copy full SHA for e53cd38 - Browse repository at this point
Copy the full SHA e53cd38View commit details -
Configuration menu - View commit details
-
Copy full SHA for e119095 - Browse repository at this point
Copy the full SHA e119095View commit details -
The tests didn't consider that in ci environment the spinners don't spin and `raw mode` is used.
Configuration menu - View commit details
-
Copy full SHA for 22565bb - Browse repository at this point
Copy the full SHA 22565bbView commit details -
Configuration menu - View commit details
-
Copy full SHA for 2e28589 - Browse repository at this point
Copy the full SHA 2e28589View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4067f82 - Browse repository at this point
Copy the full SHA 4067f82View commit details -
Configuration menu - View commit details
-
Copy full SHA for 681514d - Browse repository at this point
Copy the full SHA 681514dView commit details -
Configuration menu - View commit details
-
Copy full SHA for bc77a34 - Browse repository at this point
Copy the full SHA bc77a34View commit details -
Configuration menu - View commit details
-
Copy full SHA for 33e34c9 - Browse repository at this point
Copy the full SHA 33e34c9View commit details -
Configuration menu - View commit details
-
Copy full SHA for 58a0ad5 - Browse repository at this point
Copy the full SHA 58a0ad5View commit details
Commits on Sep 29, 2020
-
Configuration menu - View commit details
-
Copy full SHA for 4182213 - Browse repository at this point
Copy the full SHA 4182213View commit details -
Improve `applyStatusOverrides` by a lot. Seriously don't even look at the code before that, it was really bad.
Configuration menu - View commit details
-
Copy full SHA for b162b93 - Browse repository at this point
Copy the full SHA b162b93View commit details -
Configuration menu - View commit details
-
Copy full SHA for 492d748 - Browse repository at this point
Copy the full SHA 492d748View commit details -
🎄 Replace
chalk
withcolorette
This reduces bundle size significantly and its a drop in replacement, meaning no code changes were required.
Configuration menu - View commit details
-
Copy full SHA for 86252f4 - Browse repository at this point
Copy the full SHA 86252f4View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2637d4c - Browse repository at this point
Copy the full SHA 2637d4cView commit details -
Configuration menu - View commit details
-
Copy full SHA for dddbf1e - Browse repository at this point
Copy the full SHA dddbf1eView commit details