This repository has been archived by the owner on Oct 6, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
3,050 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
|
||
.skautbazar_row_hidden{ | ||
display: none; | ||
} | ||
|
||
.skautbazar_table{ | ||
width: 100%; | ||
} | ||
|
||
.skautbazar_table td{ | ||
padding: 5px; | ||
vertical-align: top; | ||
text-align: left; | ||
} | ||
|
||
.skautbazar_table_header{ | ||
width: 20%; | ||
} | ||
|
||
.required-info{ | ||
color: red; | ||
padding-left: 20px; | ||
} | ||
|
||
.skautbazar_buttons{ | ||
display: block; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,216 @@ | ||
.skautbazar_post{ | ||
width: 100%; | ||
padding: 30px; | ||
margin-bottom: 32px; | ||
background-color: #eee; | ||
} | ||
|
||
.skautbazar_post:last-child{ | ||
border-bottom: none; | ||
} | ||
|
||
.skautbazar_post p{ | ||
|
||
margin: 0; | ||
padding: 0; | ||
} | ||
|
||
.skautbazar_post_heading{ | ||
line-height: 140%; | ||
margin: 0; | ||
padding: 0; | ||
display: inline; | ||
} | ||
|
||
.skautbazar_infotext{ | ||
line-height: 180%; | ||
padding-bottom: 9px; | ||
} | ||
|
||
.skautbazar_clear{ | ||
clear: both; | ||
} | ||
|
||
.skatubazar_post_img{ | ||
width: 44%; | ||
float: left; | ||
} | ||
|
||
.skatubazar_post_img img{ | ||
width: 100%; | ||
height: auto; | ||
} | ||
|
||
.skatubazar_post_img img{ | ||
width: 100%; | ||
height: auto; | ||
} | ||
|
||
.skatubazar_post_box{ | ||
width: 55%; | ||
float: right; | ||
} | ||
|
||
.skautbazar_prev_img{ | ||
|
||
padding: 20px; | ||
} | ||
|
||
.skautbazar_prev_img img{ | ||
padding-right: 20px; | ||
padding-top: 10px; | ||
} | ||
|
||
.skautbazar_post_info{ | ||
padding: 20px 0; | ||
} | ||
|
||
.skatubazar_post_category{ | ||
padding: 20px 0; | ||
} | ||
|
||
.skautbazar_rezervace{ | ||
text-align: right; | ||
} | ||
|
||
.skautbazar_rezervace a{ | ||
display: inline-block; | ||
text-align: center; | ||
padding: 6px 14px; | ||
background-color: green; | ||
text-decoration: none !important; | ||
color: #fff; | ||
-webkit-border-radius: 4px; | ||
-moz-border-radius: 4px; | ||
border-radius: 4px; | ||
} | ||
|
||
.skautbazar_rezervovano{ | ||
background-color: red; | ||
text-align: center; | ||
padding: 6px 14px; | ||
color: #fff; | ||
-webkit-border-radius: 4px; | ||
-moz-border-radius: 4px; | ||
border-radius: 4px; | ||
} | ||
|
||
.skautbazar_emailbox_bg{ | ||
display: none; | ||
position: fixed; | ||
overflow-y: scroll; | ||
top: 0; | ||
left: 0; | ||
right: 0; | ||
bottom: 0; | ||
z-index: 8888 !important; | ||
|
||
width: 100%; | ||
height: 100%; | ||
|
||
-webkit-animation: fade-in .25s ease-in; | ||
-moz-animation-name: fade-in .25s ease-in; | ||
-ms-animation-name: fade-in .25s ease-in; | ||
-o-animation-name: fade-in .25s ease-in; | ||
animation-name: fade-in .25s ease-in; | ||
|
||
|
||
background-color: rgba(0, 0, 0, 0.8); | ||
} | ||
|
||
.skautbazar_emailbox{ | ||
display: block; | ||
position: relative; | ||
margin: auto; | ||
width: 600px; | ||
top: 50%; | ||
margin-top: -150px; | ||
padding: 30px; | ||
background-color: #fff; | ||
} | ||
|
||
.skautbazar_email_close{ | ||
float: right; | ||
} | ||
|
||
body{ | ||
position: relative; | ||
height: 100%; | ||
min-height: 100%; | ||
} | ||
|
||
|
||
.skatubazar_post_category{ | ||
|
||
} | ||
|
||
.skautbazar_infotext{ | ||
width: 70%; | ||
float: left; | ||
} | ||
|
||
.skautbazar_rezervace{ | ||
width: 29%; | ||
float: right; | ||
} | ||
|
||
.skautbazar_pagination{ | ||
list-style-type: none; | ||
width: 100%; | ||
} | ||
|
||
.skautbazar_pagination li{ | ||
float: left; | ||
} | ||
|
||
.skautbazar_pagination li a{ | ||
display: block; | ||
float: left; | ||
margin: 0 4px; | ||
} | ||
|
||
.skautbazar_post_box_full{ | ||
width: 100%; | ||
} | ||
|
||
@media screen and (max-width: 460px) { | ||
.skatubazar_post_img, | ||
.skatubazar_post_box, | ||
.skautbazar_prev_img, | ||
.skatubazar_post_category, | ||
.skautbazar_infotext, | ||
.skautbazar_infotext, | ||
.skautbazar_rezervace | ||
{ | ||
width: 100%; | ||
} | ||
|
||
.skautbazar_prev_img{ | ||
margin: 0; | ||
padding: 0; | ||
} | ||
|
||
.skautbazar_post_heading{ | ||
margin-top: 1em; | ||
margin-bottom: 0; | ||
padding-bottom: 0; | ||
} | ||
|
||
.skautbazar_post_info{ | ||
padding: 0; | ||
} | ||
|
||
.skatubazar_post_box{ | ||
margin-top: 10px; | ||
} | ||
|
||
.skautbazar_rezervace{ | ||
margin-top: 10px !important; | ||
float: left; | ||
padding-top: 15px; | ||
} | ||
|
||
|
||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
jQuery(document).ready(function($) { | ||
|
||
// $('#title').hide(); | ||
|
||
|
||
if ($('.skautbazar_intro_image_button').length > 0) { | ||
if ( typeof wp !== 'undefined' && wp.media && wp.media.editor) { | ||
$('.wrap').on('click', '.skautbazar_intro_image_button', function(e) { | ||
e.preventDefault(); | ||
var button = $(this); | ||
var $img_id = $('#skautbazar_image_id'); | ||
var $img = $('#skautbazar_intro_image'); | ||
|
||
wp.media.editor.send.attachment = function(props, attachment) { | ||
$img_id.val(attachment.id); | ||
$img.css({'display':'inline'}); | ||
$img.attr('src', attachment.url); | ||
}; | ||
wp.media.editor.open(button); | ||
|
||
return false; | ||
}); | ||
} | ||
}; | ||
|
||
$('.skautbazar_intro_image_delete_button').click(function(e){ | ||
e.preventDefault(); | ||
var $img_id = $('#skautbazar_image_id'); | ||
var $img = $('#skautbazar_intro_image'); | ||
$img_id.val(''); | ||
$img.css({'display':'none'}); | ||
$img.attr('src', '#'); | ||
}); | ||
|
||
|
||
|
||
|
||
switch($('.skautbazar_type').val()){ | ||
case 'exchange': | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
$('#skautbazar_row_exchange.skautbazar_row_hidden').css({'display':'table-row'}); | ||
break; | ||
case 'price': | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
$('#skautbazar_row_price.skautbazar_row_hidden').css({'display':'table-row'}); | ||
break; | ||
default: | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
break; | ||
} | ||
|
||
|
||
|
||
var $check = $('#skautbazar_status').val(); | ||
if($check == 2 || $check == 3 ) $('#skautbazar_row_reservation_email.skautbazar_row_hidden').css({'display':'table-row'}); | ||
|
||
$('#skautbazar_status').change(function(){ | ||
if($(this).val() == 1) $('#skautbazar_row_reservation_email.skautbazar_row_hidden').css({'display':'none'}); | ||
else $('#skautbazar_row_reservation_email.skautbazar_row_hidden').css({'display':'table-row'}); | ||
}); | ||
|
||
|
||
|
||
$('.skautbazar_type').change(function(){ | ||
$('skautbazar_row').css({'display':'none'}); | ||
switch($(this).val()){ | ||
case 'exchange': | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
$('#skautbazar_row_exchange.skautbazar_row_hidden').css({'display':'table-row'}); | ||
break; | ||
case 'price': | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
$('#skautbazar_row_price.skautbazar_row_hidden').css({'display':'table-row'}); | ||
break; | ||
default: | ||
$('.skautbazar_row_hidden').css({'display':'none'}); | ||
break; | ||
} | ||
}); | ||
|
||
|
||
|
||
$('#post').submit(function(e){ | ||
$('.required-info, .skatubazar_error').remove(); | ||
var error = true; | ||
|
||
$('.required').each(function(){ | ||
error = false; | ||
if( $(this).val() == '-1' || $(this).val() == '' ){ | ||
$(this).after('<span class="required-info">'+ translation.fill_required_field +'</span>'); | ||
e.preventDefault(); | ||
} | ||
}); | ||
|
||
if( $('#skautbazar_type_author').val() == 'price' && $('#skautbazar_price').val() == '' ) { | ||
$('#skautbazar_price').after('<span class="required-info">'+ translation.fill_required_field +'</span>'); | ||
error = false; | ||
} | ||
|
||
if( $('#skautbazar_type_author').val() == 'exchange' && $('#skautbazar_exchange').val() == '' ) { | ||
$('#skautbazar_exchange').after('<span class="required-info">'+ translation.fill_required_field +'</span>'); | ||
error = false; | ||
} | ||
|
||
if(!error) $('.wrap h2').after('<div class="error skatubazar_error"><p>'+ translation.fill_required_field +'</p></div>'); | ||
}); | ||
|
||
|
||
|
||
$('#skautbazar_cancel_reservation').click(function(e){ | ||
e.preventDefault(); | ||
|
||
$('.status_message').html( translation.active ); | ||
|
||
$('#skautbazar_buyer_email').val(''); | ||
$('#skautbazar_status').val(1); | ||
$(this).css({'display':'none'}); | ||
$('#skautbazar_buyer_email').css({'display':'none'}); | ||
}); | ||
|
||
|
||
|
||
}); |
Oops, something went wrong.