Removing lastLoginModal from DOM

This commit is contained in:
Bruno Alves de Faria committed 2017-03-21 10:16:46 -03:00
1 parent 91abaf8a60
commit c3afd068a4
11 files changed
+54 -47

No files matched your search

@@ -1,2 +1,14 @@
.modal .modal-footer:empty
display: none
.modal
.modal-header:empty, .modal-footer:empty
display: none
.modal-blank
.modal-content
border: 0
.modal-header, .modal-footer
display: none
.modal-body
padding: 0
@@ -4,21 +4,12 @@
{{#form class='modal-content' hideValidationBox=true
api=(extend instance.api instance.data.api) schema=this.schema
}}
<div class="modal-header">
{{#button class='close' action='cancel'
tagAttributes=(extend this.tagAttributes
data-dismiss='modal' aria-label='Close'
)
}}<span aria-hidden="true">&times;</span>{{/button}}
<h4 class="modal-title">
{{#if this.titleIcon}}<i class="{{this.titleIcon}}"></i>{{/if}}
<span>{{this.title}}</span>
</h4>
</div>
{{>dialogHeader this}}
<div class="modal-body">
{{>UI.contentBlock}}
</div>
<div class="modal-footer">
{{>section 'dialogFooter'}}
{{#button action='cancel'
class=(concat 'btn btn-cancel ' (choose this.cancelClass 'btn-default'))
tagAttributes=(extend this.tagAttributes data-dismiss='modal')
@@ -0,0 +1,16 @@
<template name="dialogHeader">
<div class="modal-header">
{{>section 'dialogHeader'}}
{{#if this.title}}
{{#button class='close' action='cancel'
tagAttributes=(extend this.tagAttributes
data-dismiss='modal' aria-label='Close'
)
}}<span aria-hidden="true">&times;</span>{{/button}}
<h4 class="modal-title">
{{#if this.titleIcon}}<i class="{{this.titleIcon}}"></i>{{/if}}
<span>{{this.title}}</span>
</h4>
{{/if}}
</div>
</template>
@@ -2,14 +2,7 @@
<div id="{{this.id}}" class="modal fade" tabindex="-1" role="dialog">
<div class="modal-dialog {{this.dialogClass}}" role="document">
<div class="modal-content">
<div class="modal-header">
{{#button class='close' action='cancel'
tagAttributes=(extend this.tagAttributes
data-dismiss='modal' aria-label='Close'
)
}}<span aria-hidden="true">&times;</span>{{/button}}
<h4 class="modal-title">{{this.title}}</h4>
</div>
{{>dialogHeader this}}
<div class="modal-body">
{{>UI.contentBlock}}
</div>
@@ -1,3 +1,4 @@
import { Meteor } from 'meteor/meteor';
import { Template } from 'meteor/templating';
import { _ } from 'meteor/underscore';
import { OHIF } from 'meteor/ohif:core';
@@ -9,6 +10,11 @@ Template.dialogSimple.onCreated(() => {
const $modal = instance.$('.modal');
$modal.on('hidden.bs.modal', () => instance.data.promiseResolve()).modal('hide');
};
// Automatically close the modal if a timeout value was given
if (instance.data.timeout) {
Meteor.setTimeout(instance.close, instance.data.timeout);
}
});
Template.dialogSimple.onRendered(() => {
@@ -1,6 +1,7 @@
import './dialog/confirm.html';
import './dialog/form.html';
import './dialog/form.js';
import './dialog/header.html';
import './dialog/info.html';
import './dialog/info.js';
import './dialog/loading.html';
+1
View File
@@ -46,6 +46,7 @@ OHIF.blaze.getParentTemplateView = view => {
let currentView = view;
while (currentView) {
currentView = currentView.originalParentView || currentView.parentView;
if (!currentView || !currentView.name) return;
if (currentView.name.indexOf('Template.') > -1) {
return currentView;
}