Primeros cambios por cliente y pasando a responsive

This commit is contained in:
2021-01-06 23:43:16 -03:00
parent b7003db753
commit d31626b4a6
18 changed files with 2951 additions and 1603 deletions

View File

@ -1,41 +1,3 @@
var proportionals = []
var widths = []
var heights = []
var changeables = []
function register_resizeables() {
proportionals.push($('img'))
//widths.push()
heights.push($('#backgrounds div'))
changeables.push($('.sticky'))
}
const vw = Math.max(document.documentElement.clientWidth || 0, window.innerWidth || 0)
const vh = Math.max(document.documentElement.clientHeight || 0, window.innerHeight || 0)
function mod_height(elem, p) {
elem.height = (elem.height * p)
}
function mod_width(elem, p) {
elem.width = (elem.width * p)
}
function mod_dim(elem, p) {
mod_width(elem, p)
mod_height(elem, p)
}
function resize() {
let p = 400 / 1080
$.each(proportionals, (i, el) => {
mod_dim(el, p)
})
$.each(widths, (i, el) => {
mod_width(el, p)
})
$.each(heights, (i, el) => {
mod_height(el, p)
})
}
class Amount {
constructor(elem) {
this.elem = elem
@ -152,10 +114,8 @@ class Colors {
}
let smtp = {
Host: 'smtp.google.com',
Username: 'rsalinas85@gmail.com',
Password: 'salinas1234',
From: 'ventas@3dstand.cl'
SecureToken: '4adcdc1f-6b6e-4e60-ab72-20da4c329b09',
From: 'contacto@3dstand.cl'
}
let sticky_form = {
@ -197,9 +157,7 @@ let cotiza_form = {
this.elem.find('[name="mensaje"]').val()
]
let content = {
Host: smtp.Host,
Username: smtp.Username,
Password: smtp.Password,
SecureToken: smtp.SecureToken,
To: email,
From: smtp.From,
Subject: 'Cotizacion - ' + (new Date()).toLocaleString('es-CL', {timezone: "UTC-3"}),
@ -211,8 +169,7 @@ let cotiza_form = {
}
]
}
console.debug(email)
//Email.send()
Email.send(content)
}
}
let conversemos_form = {
@ -233,14 +190,13 @@ let conversemos_form = {
this.elem.find('[name="mensaje"]').val()
]
let content = {
Host: smtp.Host,
Username: smtp.Username,
Password: smtp.Password,
SecureToken: smtp.SecureToken,
From: smtp.From,
To: email,
Subject: 'Contacto ' + (new Date()).toLocaleString('es-CL', {timezone: "UTC-3"}),
Body: body.join('<br />')
}
Email.send(content)
}
}
@ -295,11 +251,6 @@ let testimonios = {
}
$(document).ready(function() {
register_resizeables()
if (vw < 1080) {
resize()
}
$('.menu.sticky').sticky()
$('.column2 .sticky').sticky({
@ -309,8 +260,6 @@ $(document).ready(function() {
$('.shopping.cart').innerText = 0
window.onresize = resize;
let sticky_amount = new Amount($('.sticky .input input[name="cantidad"]'))
let sticky_color = new Colors($('.sticky .colores'), true)
sticky_form.setup()