Improve JSDoc for some components

Apply suggestions from code review

Co-authored-by: Nelson Chan <chakflying@hotmail.com>
pull/1550/head
Matthew Nickson 3 years ago committed by GitHub
parent 213aca4fc3
commit 2170229031
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -58,7 +58,7 @@ export default {
this.modal.show(); this.modal.show();
}, },
/** /**
* @emits string A string that simply says "yes" * @emits "yes" - Notify the parent when Yes is pressed
*/ */
yes() { yes() {
this.$emit("yes"); this.$emit("yes");

@ -17,7 +17,7 @@
export default { export default {
props: { props: {
/** Size of the heart beat bar */ /** Size of the heartbeat bar */
size: { size: {
type: String, type: String,
default: "big", default: "big",
@ -27,7 +27,7 @@ export default {
type: Number, type: Number,
required: true, required: true,
}, },
/** Array of the monitors heart beats */ /** Array of the monitors heartbeats */
heartbeatList: { heartbeatList: {
type: Array, type: Array,
default: null, default: null,
@ -171,7 +171,8 @@ export default {
}, },
/** /**
* Get the title of the beat * Get the title of the beat.
* Used as the hover tooltip on the heartbeat bar.
* @param {Object} beat Beat to get title from * @param {Object} beat Beat to get title from
* @returns {string} * @returns {string}
*/ */

@ -34,7 +34,7 @@ export default {
type: String, type: String,
default: "" default: ""
}, },
/** Maximum lenght of the input */ /** Maximum length of the input */
maxlength: { maxlength: {
type: Number, type: Number,
default: 255 default: 255

@ -270,7 +270,7 @@ export default {
} }
}, },
/** /**
* Set colour of text * Get colour of text inside the tag
* @param {Object} option Object representing color choice. If * @param {Object} option Object representing color choice. If
* option.color is set, the text color will be white, else it * option.color is set, the text color will be white, else it
* be chosen based upon application theme * be chosen based upon application theme
@ -357,7 +357,7 @@ export default {
this.$root.getSocket().emit("deleteMonitorTag", tagId, monitorId, value, resolve); this.$root.getSocket().emit("deleteMonitorTag", tagId, monitorId, value, resolve);
}); });
}, },
/** Called as user types input */ /** Handle pressing Enter key when inside the modal */
onEnter() { onEnter() {
if (!this.validateDraftTag.invalid) { if (!this.validateDraftTag.invalid) {
this.addDraftTag(); this.addDraftTag();

@ -29,12 +29,12 @@
<script> <script>
export default { export default {
props: { props: {
/** Heading to use */ /** Heading of the Section */
heading: { heading: {
type: String, type: String,
default: "", default: "",
}, },
/** Should the selection be open by default? */ /** Should the section be open by default? */
defaultOpen: { defaultOpen: {
type: Boolean, type: Boolean,
default: false, default: false,

Loading…
Cancel
Save