help-and-feedback-component
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -71,3 +71,3 @@ { | ||
"name": "content", | ||
"type": "String", | ||
"type": "Any", | ||
"attr": "content" | ||
@@ -74,0 +74,0 @@ }, |
export class HelpAndFeedback { | ||
constructor() { | ||
this.isModalOpen = false; | ||
// Variables | ||
this.content = {}; | ||
} | ||
// Event listener | ||
closedModalHandler(event) { | ||
console.log('got close modal event'); | ||
console.log(event); | ||
closedModalHandler() { | ||
this.hideModal(); | ||
@@ -16,3 +16,2 @@ } | ||
showModal(event) { | ||
console.log('clicked the button'); | ||
// Show a modal with static information | ||
@@ -19,0 +18,0 @@ if (this.isModalOpen) { |
@@ -6,3 +6,6 @@ export class ModalHelpAndFeedback { | ||
componentWillLoad() { | ||
// this.setColors(this.backgroundColor); | ||
// this.setColors(this.backgroundColor); | ||
console.log(this.content); | ||
if (this.content.links) { | ||
} | ||
} | ||
@@ -19,3 +22,4 @@ closeModal(event) { | ||
h("i", { class: 'material-icons' }, "close"))), | ||
h("div", null, this.content))); | ||
h("ul", null, this.content.links.map((link) => h("li", null, | ||
h("a", { href: link.url }, link.text)))))); | ||
} | ||
@@ -33,3 +37,3 @@ else { | ||
"content": { | ||
"type": String, | ||
"type": "Any", | ||
"attr": "content" | ||
@@ -36,0 +40,0 @@ }, |
@@ -5,2 +5,2 @@ // HelpAndFeedbackComponent: Host Data, ES Module/ES5 Target | ||
export var ModalHelpAndFeedback = ["modal-help-and-feedback",function(){return(import("./help-and-feedback.js")).then(function(m){return m.ModalHelpAndFeedback})},1,[["backgroundColor",1,0,"background-color",2],["content",1,0,1,2],["isModalOpen",2,0,"is-modal-open",3],["modalElement",7]]]; | ||
export var ModalHelpAndFeedback = ["modal-help-and-feedback",function(){return(import("./help-and-feedback.js")).then(function(m){return m.ModalHelpAndFeedback})},1,[["backgroundColor",1,0,"background-color",2],["content",1,0,1,1],["isModalOpen",2,0,"is-modal-open",3],["modalElement",7]]]; |
@@ -6,7 +6,7 @@ /*! Built with http://stenciljs.com */ | ||
this.isModalOpen = false; | ||
// Variables | ||
this.content = {}; | ||
} | ||
// Event listener | ||
HelpAndFeedback.prototype.closedModalHandler = function (event) { | ||
console.log('got close modal event'); | ||
console.log(event); | ||
HelpAndFeedback.prototype.closedModalHandler = function () { | ||
this.hideModal(); | ||
@@ -19,3 +19,2 @@ }; | ||
HelpAndFeedback.prototype.showModal = function (event) { | ||
console.log('clicked the button'); | ||
// Show a modal with static information | ||
@@ -111,3 +110,6 @@ if (this.isModalOpen) { | ||
ModalHelpAndFeedback.prototype.componentWillLoad = function () { | ||
// this.setColors(this.backgroundColor); | ||
// this.setColors(this.backgroundColor); | ||
console.log(this.content); | ||
if (this.content.links) | ||
; | ||
}; | ||
@@ -120,3 +122,3 @@ ModalHelpAndFeedback.prototype.closeModal = function (event) { | ||
if (this.isModalOpen) { | ||
return (h("div", { class: 'modal__help-and-feedback open' }, h("div", { class: 'modal__toolbar' }, h("h1", { class: 'modal__title' }, "Help and feedback"), h("button", { class: 'material icon-button', "aria-label": 'close help and feedback', onClick: function (event) { return _this.closeModal(event); } }, h("i", { class: 'material-icons' }, "close"))), h("div", null, this.content))); | ||
return (h("div", { class: 'modal__help-and-feedback open' }, h("div", { class: 'modal__toolbar' }, h("h1", { class: 'modal__title' }, "Help and feedback"), h("button", { class: 'material icon-button', "aria-label": 'close help and feedback', onClick: function (event) { return _this.closeModal(event); } }, h("i", { class: 'material-icons' }, "close"))), h("ul", null, this.content.links.map(function (link) { return h("li", null, h("a", { href: link.url }, link.text)); })))); | ||
} | ||
@@ -140,3 +142,3 @@ else { | ||
"content": { | ||
"type": String, | ||
"type": "Any", | ||
"attr": "content" | ||
@@ -143,0 +145,0 @@ }, |
@@ -126,2 +126,2 @@ /*! Built with http://stenciljs.com */ | ||
})(window, document, "HelpAndFeedbackComponent","help-and-feedback-component",0,"help-and-feedback-component.core.js","es5-build-disabled.js","hydrated",[["help-and-feedback","help-and-feedback",1,[["background",1,0,1,2],["color",1,0,1,2],["dataUrl",1,0,"data-url",2],["iconButtonElement",7],["isModalOpen",5]],0,[["closedModal","closedModalHandler"]]],["modal-help-and-feedback","help-and-feedback",1,[["backgroundColor",1,0,"background-color",2],["content",1,0,1,2],["isModalOpen",2,0,"is-modal-open",3],["modalElement",7]]]],HTMLElement.prototype); | ||
})(window, document, "HelpAndFeedbackComponent","help-and-feedback-component",0,"help-and-feedback-component.core.js","es5-build-disabled.js","hydrated",[["help-and-feedback","help-and-feedback",1,[["background",1,0,1,2],["color",1,0,1,2],["dataUrl",1,0,"data-url",2],["iconButtonElement",7],["isModalOpen",5]],0,[["closedModal","closedModalHandler"]]],["modal-help-and-feedback","help-and-feedback",1,[["backgroundColor",1,0,"background-color",2],["content",1,0,1,1],["isModalOpen",2,0,"is-modal-open",3],["modalElement",7]]]],HTMLElement.prototype); |
@@ -7,7 +7,7 @@ /*! Built with http://stenciljs.com */ | ||
this.isModalOpen = false; | ||
// Variables | ||
this.content = {}; | ||
} | ||
// Event listener | ||
closedModalHandler(event) { | ||
console.log('got close modal event'); | ||
console.log(event); | ||
closedModalHandler() { | ||
this.hideModal(); | ||
@@ -20,3 +20,2 @@ } | ||
showModal(event) { | ||
console.log('clicked the button'); | ||
// Show a modal with static information | ||
@@ -89,3 +88,5 @@ if (this.isModalOpen) { | ||
componentWillLoad() { | ||
// this.setColors(this.backgroundColor); | ||
// this.setColors(this.backgroundColor); | ||
console.log(this.content); | ||
if (this.content.links) ; | ||
} | ||
@@ -102,3 +103,4 @@ closeModal(event) { | ||
h("i", { class: 'material-icons' }, "close"))), | ||
h("div", null, this.content))); | ||
h("ul", null, this.content.links.map((link) => h("li", null, | ||
h("a", { href: link.url }, link.text)))))); | ||
} | ||
@@ -116,3 +118,3 @@ else { | ||
"content": { | ||
"type": String, | ||
"type": "Any", | ||
"attr": "content" | ||
@@ -119,0 +121,0 @@ }, |
@@ -70,3 +70,3 @@ import './stencil.core'; | ||
'backgroundColor': string; | ||
'content': string; | ||
'content': any; | ||
'isModalOpen': boolean; | ||
@@ -96,3 +96,3 @@ } | ||
'backgroundColor'?: string; | ||
'content'?: string; | ||
'content'?: any; | ||
'isModalOpen'?: boolean; | ||
@@ -99,0 +99,0 @@ 'onClosedModal'?: (event: CustomEvent) => void; |
@@ -8,4 +8,4 @@ import '../../stencil.core'; | ||
isModalOpen: boolean; | ||
content: string; | ||
closedModalHandler(event: UIEvent): void; | ||
content: {}; | ||
closedModalHandler(): void; | ||
setColors(color: string): void; | ||
@@ -12,0 +12,0 @@ showModal(event: UIEvent): void; |
@@ -7,3 +7,3 @@ import '../../stencil.core'; | ||
backgroundColor: string; | ||
content: string; | ||
content: any; | ||
closedModal: EventEmitter; | ||
@@ -10,0 +10,0 @@ componentWillLoad(): void; |
@@ -205,2 +205,6 @@ import '../../stencil.core'; | ||
import '../../stencil.core'; | ||
import '../../stencil.core'; | ||
import '../../stencil.core'; | ||
import '../../stencil.core'; | ||
import '../../stencil.core'; | ||
export declare class TopAppBar { | ||
@@ -207,0 +211,0 @@ topBarElement: HTMLElement; |
{ | ||
"name": "help-and-feedback-component", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "Material icon button made with StencilJS", | ||
@@ -5,0 +5,0 @@ "module": "dist/esm/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
291746
6157