Skip to content
Snippets Groups Projects
Commit 55903d25 authored by Jacek Lebioda's avatar Jacek Lebioda
Browse files

Merge branch 'box-hider' into 'develop'

Corrections for Safari and Firefox of the new landing page

See merge request R3/howto-cards!199
parents 7f4399ba 46fde328
No related branches found
No related tags found
No related merge requests found
......@@ -139,7 +139,7 @@
/* min-height: calc(50% - 20px); */
min-height: 110px;
padding: 10px 10px 5px 10px;
text-align: -webkit-center;
text-align: center;
transition: height var(--animation-time) linear, border-color var(--animation-time) linear;
background-color: white;
font-size: 15px;
......
......@@ -140,6 +140,9 @@ window.cardDrop = function(event) {
rebuild_cards();
}
refresh_drop_to_add_button();
if (event.preventDefault) event.preventDefault();
if (event.stopPropagation) event.stopPropagation();
}
window.cardDropDiscard = function(event) {
let serializedCard = event.dataTransfer.getData("card");
......@@ -154,12 +157,16 @@ window.cardDropDiscard = function(event) {
rebuild_cards();
}
refresh_drop_to_add_button();
if (event.preventDefault) event.preventDefault();
if (event.stopPropagation) event.stopPropagation();
}
window.allowDrop = function(event) {
event.preventDefault();
}
window.rebuild_cards = function() {
$left_inner_container.replaceChildren();
while ($left_inner_container.firstChild) {
$left_inner_container.removeChild($left_inner_container.firstChild);
}
for (const card of window.cards) {
let card_el = create_card(card.icon, card.title, card.caption, card.link);
attach_card($left_inner_container, card_el);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment