diff --git a/components/calcModels.vue b/components/calcModels.vue index 220cb23..5689f78 100644 --- a/components/calcModels.vue +++ b/components/calcModels.vue @@ -23,7 +23,6 @@ const cameraStat = reactive({ }) const pointLight = ref() -const pointLight2 = ref() const loadAll = async () => { const { scene: light } = await useGLTF('/models_light/zabor_so_svetom.glb') pointLight.value = light.children[2] @@ -35,7 +34,7 @@ const loadAll = async () => { pointLight.value.shadow.mapSize.x = 512 * j pointLight.value.shadow.mapSize.y = 512 * j - const k = 5 + const k = 3 pointLight.value.position.x = pointLight.value.position.x * k pointLight.value.position.y = pointLight.value.position.y * k pointLight.value.position.z = pointLight.value.position.z * k diff --git a/components/calcValues.vue b/components/calcValues.vue index 7e2a7df..a2306ee 100644 --- a/components/calcValues.vue +++ b/components/calcValues.vue @@ -136,11 +136,6 @@ watch(() => form_state, changeParametres, { deep: true }) const isModalOpen = useState('modal_open', () => false) const toggleModal = () => { isModalOpen.value = !isModalOpen.value - if (isModalOpen.value == true) { - document.body.classList.add('modal-opened') - } else { - document.body.classList.remove('modal-opened') - } } const goal = (target: string, params: object) => { const nuxtApp = useNuxtApp() diff --git a/components/expDiagram.vue b/components/expDiagram.vue index f6fc334..e5a8cc6 100644 --- a/components/expDiagram.vue +++ b/components/expDiagram.vue @@ -63,7 +63,7 @@ onMounted(() => { Загрузка 3D модели - + diff --git a/components/modal.vue b/components/modal.vue index c362e87..a43fd0b 100644 --- a/components/modal.vue +++ b/components/modal.vue @@ -36,7 +36,7 @@ const modal_data = reactive({ email: undefined, phone: undefined, name: undefined, - policy: true + policy: false }) const modal_form = reactive({ @@ -75,6 +75,13 @@ const validate = () => { } } watch(modal_data, validate) +watch(isModalOpen, () => { + if (isModalOpen.value == true) { + document.body.classList.add('modal-opened') + } else { + document.body.classList.remove('modal-opened') + } +}) const submit = async (e: any) => { goal('submit_form', modal_data) @@ -216,8 +223,9 @@ const policy = () => { @keypress="validateInput" />
-
{{ total_txt && total_txt.total[0] }} diff --git a/components/model/fence.vue b/components/model/fence.vue index 44a200f..222c2fd 100644 --- a/components/model/fence.vue +++ b/components/model/fence.vue @@ -53,6 +53,7 @@ const instanced_lamelle_material = props.models.lamelle.children[0].material const instanced_lamelle_count = 24 const instanced_v = [instanced_lamelle_geometry, instanced_lamelle_material, instanced_lamelle_count] watch([instanced_lamelle, fence_section, extra_section, lamelles_count, extra], () => { + // console.log(props.index, instanced_v, instanced_lamelle.value) for (let i = 0; i < instanced_lamelle_count; i++) { if (instanced_lamelle.value) { const scale_x = (((extra.value as number) || fence_section.value) * 10) diff --git a/composables/useCalc.ts b/composables/useCalc.ts index c11aef2..b164771 100644 --- a/composables/useCalc.ts +++ b/composables/useCalc.ts @@ -16,5 +16,5 @@ export const use_section_count = () => useState('section_count', () => n) export const use_extra_section = () => useState('extra_section', () => 0) export const use_total_length = () => useState('total_length', () => (((min + 104) * n) + 104) * 0.001) export const use_min_length = () => useState('min_length', () => 700) -export const use_max_size = () => useState('max_size', () => 40) +export const use_max_size = () => useState('max_size', () => 20) export const use_explosion_state = () => useState('explosion_state', () => false) \ No newline at end of file