Skip to content

Commit

Permalink
Merge pull request #323 from SlateFoundation/develop
Browse files Browse the repository at this point in the history
Release: v2.17.3
  • Loading branch information
themightychris authored Jan 27, 2022
2 parents f2fd0d1 + 42888f6 commit 74f5e26
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 3 deletions.
10 changes: 10 additions & 0 deletions php-config/Slate/UI/Tools.config.d/utilities.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php

if (empty($GLOBALS['Session']) || !$GLOBALS['Session']->hasAccountLevel('Administrator')) {
return;
}

Slate\UI\Tools::$tools['Utilities']['Power Tools'] = [
'_href' => '/powertools',
'_icon' => 'gears'
];
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@

// dataview properties
loadMask: false,
emptyText: 'No contacts have been linked or created yet.',
emptyText: `
<div class="empty-text">No related contacts linked</div>
`,
disableSelection: true,
itemSelector: '.x-dataview-item',
tpl: [`
Expand Down Expand Up @@ -78,7 +80,7 @@
</div>
</div>
</tpl>
<div class="relationship-creator">
<div class="relationship-creator" data-action="add-related-person" role="button">
<i class="fa fa-plus-circle"></i> Add a related person&hellip;
</div>
`,{
Expand Down Expand Up @@ -175,7 +177,7 @@
var me = this;

me.callParent(arguments);
me.mon(me.el, 'click', 'onRelationshipCreatorClick', me, { delegate: '.relationship-creator' });
me.mon(me.el, 'click', 'onRelationshipCreatorClick', me, { delegate: '[data-action="add-related-person"]' });
},

// disable built-in focus manipulation that can interfere with editing
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
.contacts-list {

.empty-text {
padding: 1em;
}

.x-dataview-item,
.relationship-creator {
background-color: $grid-row-cell-background-color;
Expand Down Expand Up @@ -79,5 +83,13 @@
color: $success-color;
margin-right: .125em;
}

&:hover {
background-color: $grid-row-cell-over-background-color;
}

&:focus {
background-color: $grid-row-cell-focus-background-color;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@
Ext.applyIf(headerCmp, {
flex: 1,

cls: 'full-name-label muted',
padding: '0 6',
width: '100%',
tpl: '{FullName:htmlEncode}'
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,22 @@
.x-form-cb-checked .glyph-guardian {
color: $glyph-shield-color;
}

.full-name-label {
animation-duration: 250ms;
animation-fill-mode: both;
animation-name: relationship-editor-name-scoot;
animation-timing-function: cubic-bezier(0.190, 1.000, 0.220, 1.000);
z-index: 1;
}
}

@keyframes relationship-editor-name-scoot {
0% {
transform: translateY(10px);
}

100% {
transform: none;
}
}
3 changes: 3 additions & 0 deletions site-root/powertools/_index.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<?php

Emergence\RequestHandler\IndexRequestHandler::handleIndexRequest('Staff');

0 comments on commit 74f5e26

Please sign in to comment.