- Aggiunte traduzioni pagina Inglesine
- Modifiche interfaccia - Correzioni varie
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
"CWFrame_Joints": "Giunzioni",
|
||||
"CWFrame_Quantity": "Quantità",
|
||||
"CWFrame_Shape": "Forma",
|
||||
"CWFrame_Threshold": "Soglia",
|
||||
"CWFrame_Threshold": "Tipologia traverso inferiore",
|
||||
"CWFrame_Tipology": "Tipologia",
|
||||
"CWAreaF_AreaFrame": "Area Telaio",
|
||||
"CWAreaF_AggSash": "Aggiungi Ante",
|
||||
@@ -63,6 +63,7 @@
|
||||
"CWAreaS_AddInglesina": "Inglesina",
|
||||
"CWAreaS_Element": "Elementi",
|
||||
"CWAreaS_Joints": "Giunzioni",
|
||||
"CWAreaS_Add": "Aggiungi",
|
||||
"CWSplit_Sash": "Anta",
|
||||
"CWSplit_SashGroup": "Ante",
|
||||
"CWSplit_Split": "Divisione",
|
||||
@@ -96,5 +97,26 @@
|
||||
"CWAreaSp_AddSash": "Aggiungi anta",
|
||||
"CWAreaSp_CopySash": "Copia anta",
|
||||
"CWAreaSp_AddInglesina": "Aggiungi inglesina",
|
||||
"CWAreaSp_Sash": "Anta"
|
||||
"CWAreaSp_Sash": "Anta",
|
||||
"CWIng_Sash": "Anta",
|
||||
"CWIng_SashGroup": "Gruppo ante",
|
||||
"CWIng_Glass": "Vetro",
|
||||
"CWIng_Inglesina": "Inglesina",
|
||||
"CWIng_RemoveIng": "Elimina inglesina",
|
||||
"CWIng_Shape": "Forma",
|
||||
"CWIng_Horizontal": "Orizzontale",
|
||||
"CWIng_Vertical": "Verticale",
|
||||
"CWIng_Grid": "Griglia",
|
||||
"CWIng_Custom": "Personalizzata",
|
||||
"CWIng_StartVert": "Inizia verticale",
|
||||
"CWIng_Side": "Lato",
|
||||
"CWIng_Internal": "Interno",
|
||||
"CWIng_External": "Esterno",
|
||||
"CWIng_Both": "Interno & esterno",
|
||||
"CWIng_HorizIng": "Elementi orizzontali",
|
||||
"CWIng_VerticalIng": "Elementi verticali",
|
||||
"CWIng_QtyElem": "Qtà",
|
||||
"CWIng_Absolute": "Assoluta",
|
||||
"CWIng_Proportional": "Proporzionale",
|
||||
"CWIng_Percentage": "Percentuale"
|
||||
}
|
||||
@@ -1,10 +1,8 @@
|
||||
@using static WebWindowComplex.Json.WindowConst
|
||||
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-start align-items-center">
|
||||
<div class="d-flex justify-content-between align-items-center">
|
||||
<h6 class="fw-bold">@Traduci("CWHwOpt_HwOption")</h6>
|
||||
</div>
|
||||
<div class="col d-flex justify-content-md-end align-items-center">
|
||||
<button class="btn btn-primary btn-sm" type="button" @onclick="() => changeCollapsed()"><i class="@hwIcon"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
@using EgwCoreLib.Razor
|
||||
|
||||
<div class="col-lg-12 col-md-12">
|
||||
@if (!SashDimEditList.Contains(IndexSash))
|
||||
{
|
||||
<div class="d-flex justify-content-start align-items-center">
|
||||
<div class="col-md-12 col-lg-8 px-0 d-grid justify-content-start">
|
||||
<h6 class="fw-bold text-nowrap">@Traduci("CWAreaS_Sash") @(CurrSashGroup.SashList.Count == 1 ? "" : (IndexSash + 1))</h6>
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-3 px-0">
|
||||
<div class="d-flex align-items-center mb-2">
|
||||
<h6 class="fw-bold text-nowrap mb-0 w-100 text-start">@Traduci("CWAreaS_Sash") @(CurrSashGroup.SashList.Count == 1 ? "" : (IndexSash + 1))</h6>
|
||||
<div class="d-flex g-2 ms-auto">
|
||||
@if (!SashDimEditList.Contains(IndexSash))
|
||||
{
|
||||
@if(!BaseUser && CurrSashGroup.SashList.Count > 1)
|
||||
{
|
||||
<div class="dropdown px-4 w-100">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle btn-sm w-100"
|
||||
<button class="btn btn-outline-secondary dropdown-toggle btn-sm text-nowrap"
|
||||
type="button"
|
||||
@onclick="ToggleDropdown"
|
||||
aria-expanded="@isOpen">
|
||||
@@ -34,316 +33,170 @@
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-1 px-0 align-items-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" type="button" @onclick="() => doEdit(IndexSash)">
|
||||
<button class="btn btn-outline-secondary btn-sm text-nowrap" type="button" @onclick="() => doEdit(IndexSash)">
|
||||
<i class="fa-solid fa-pen"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row align-items-center justify-content-start">
|
||||
<div class="col-lg-2 col-md-12 my-2">
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="btn btn-outline-secondary d-flex align-items-center gap-2"
|
||||
}
|
||||
else
|
||||
{
|
||||
@if (!BaseUser && (!(CurrAnta.AreaList[0] is Split) || CurrAnta.AreaList[0].AreaList.Count == 0))
|
||||
{
|
||||
<div class="dropdown px-4 w-100">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle btn-sm"
|
||||
type="button"
|
||||
style="background-color: @(isOpenDropdown ? "#f8f9fa" : "#ffffff"); color: @(isOpenDropdown ? "#333333" : "");" >
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
@onclick="ToggleDropdown"
|
||||
aria-expanded="@isOpen">
|
||||
@Traduci("CWAreaS_Add")
|
||||
</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="dropdown" @onfocusout="HandleFocusOut" tabindex="0">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle d-flex align-items-center gap-2"
|
||||
type="button"
|
||||
style="background-color: @(isOpenDropdown ? "#f8f9fa" : "#ffffff"); color: @(isOpenDropdown ? "#333333" : "");"
|
||||
@onclick="ToggleDropdownOpening"
|
||||
aria-expanded="@isOpenDropdown">
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
</button>
|
||||
<ul class="dropdown-menu p-2 @(isOpenDropdown ? "show" : "")"
|
||||
style="position: absolute; min-width: 20em;">
|
||||
<div class="row g-2 row-cols-4 m-0">
|
||||
@foreach (var openingType in CurrSashDim.OpeningTypeList)
|
||||
{
|
||||
<div class="col p-0">
|
||||
<button type="button"
|
||||
class="dropdown-item d-flex flex-column align-items-center justify-content-center p-2 rounded text-center h-100 @ButtonOpeningCss(openingType.Id)"
|
||||
style="background-color: @(OpeningTypeIndex == openingType.Id ? "#d4e6fa" : "#f8f9fa");"
|
||||
@onclick="() => SelOpeningSash(openingType.Id, openingType.Name)">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(openingType.Name)"
|
||||
title="@(openingType.Name)" width="100" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-5 col-md-12 my-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWAreaS_Dimension")</span>
|
||||
@if(BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@Dimension">
|
||||
@switch (CurrSashDim.SelMeasureType.ToString())
|
||||
{
|
||||
case "ABSOLUTE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">mm</span>
|
||||
break;
|
||||
}
|
||||
case "PROPORTIONAL":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">*</span>
|
||||
break;
|
||||
}
|
||||
case "PERCENTAGE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@Dimension">
|
||||
<select class="form-select" style="max-width:6rem; background-color:#e9ecef" @bind="@MeasureTypeIndex">
|
||||
@foreach (var mType in CurrSashDim.MeasureTypeList)
|
||||
<ul class="dropdown-menu w-100 @(isOpen ? "show" : "")"
|
||||
style="min-width:0rem; max-width:10rem">
|
||||
@if (!(CurrAnta.AreaList[0] is Split))
|
||||
{
|
||||
<option value=@(mType.Id)>
|
||||
@switch (mType.Name)
|
||||
{
|
||||
case "Absolute":
|
||||
{
|
||||
<span class="input-group-text">mm</span>
|
||||
break;
|
||||
}
|
||||
case "Proportional":
|
||||
{
|
||||
<span class="input-group-text">*</span>
|
||||
break;
|
||||
}
|
||||
case "Percentage":
|
||||
{
|
||||
<span class="input-group-text">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
</option>
|
||||
<li>
|
||||
<button class="dropdown-item" @onclick="() => AddSplitToSash()">
|
||||
@Traduci("CWAreaS_AddSplit")
|
||||
</button>
|
||||
</li>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-md-12 my-2">
|
||||
<div class="d-flex justify-content-start fs-5 mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" disabled="disabled" type="checkbox" name="Handle" checked="@CurrSashDim.bHasHandle">
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" type="checkbox" name="Handle" checked="@CurrSashDim.bHasHandle" @onclick="() => ChangeHandle()">
|
||||
</div>
|
||||
}
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWAreaS_Handle")</label>
|
||||
@if (CurrAnta.AreaList[0].AreaList.Count == 0)
|
||||
{
|
||||
<li>
|
||||
<button class="dropdown-item" @onclick="() => AddInglesinaToSash()">
|
||||
@Traduci("CWAreaS_AddInglesina")
|
||||
</button>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
<button type="button" class="btn-close" aria-label="Close" @onclick="() => ClosePopup(IndexSash)"></button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="d-flex align-items-center gap-4 mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="btn btn-outline-secondary align-items-center gap-2"
|
||||
type="button"
|
||||
style="background-color: @(isOpenDropdown ? "#f8f9fa" : "#ffffff"); color: @(isOpenDropdown ? "#333333" : "");">
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="dropdown" @onfocusout="HandleFocusOut" tabindex="0">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle d-flex align-items-center gap-2"
|
||||
type="button"
|
||||
@onclick="ToggleDropdownOpening"
|
||||
aria-expanded="@isOpenDropdown">
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
</button>
|
||||
<ul class="dropdown-menu p-2 @(isOpenDropdown ? "show" : "")"
|
||||
style="position: absolute; min-width: 20em;">
|
||||
<div class="row g-2 row-cols-4 m-0">
|
||||
@foreach (var openingType in CurrSashDim.OpeningTypeList)
|
||||
{
|
||||
<div class="col p-0">
|
||||
<button type="button"
|
||||
class="dropdown-item d-flex flex-column align-items-center justify-content-center p-2 rounded text-center h-100 @ButtonOpeningCss(openingType.Id)"
|
||||
@onclick="() => SelOpeningSash(openingType.Id, openingType.Name)">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(openingType.Name)"
|
||||
title="@(openingType.Name)" width="100" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
<div class="input-group w-auto">
|
||||
<span class="input-group-text">@Traduci("CWAreaS_Dimension")</span>
|
||||
@if(BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@Dimension" style="min-width:2rem; max-width:6em;">
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">
|
||||
@(CurrSashDim.SelMeasureType.ToString() switch
|
||||
{
|
||||
"Absolute" => "mm",
|
||||
"Proportional" => "*",
|
||||
"Percentage" => "%",
|
||||
_ => CurrSashDim.SelMeasureType.ToString()
|
||||
})
|
||||
</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" class="form-control" style="min-width:2rem; max-width:6em;" @bind="@Dimension">
|
||||
<select class="form-select" style="max-width:6rem; background-color:#e9ecef" @bind="@MeasureTypeIndex">
|
||||
@foreach (var mType in CurrSashDim.MeasureTypeList)
|
||||
{
|
||||
<option value=@(mType.Id)>
|
||||
@(mType.Name switch
|
||||
{
|
||||
"Absolute" => "mm",
|
||||
"Proportional" => "*",
|
||||
"Percentage" => "%",
|
||||
_ => mType.Name
|
||||
})
|
||||
</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
</div>
|
||||
<div class="form-check d-flex align-items-center">
|
||||
@if(BaseUser)
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input me-1" type="checkbox" checked="@CurrSashDim.bHasHandle" @onclick:preventDefault>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input me-1" type="checkbox" checked="@CurrSashDim.bHasHandle" @onclick="() => ChangeHandle()">
|
||||
</div>
|
||||
}
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWAreaS_Handle")</label>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
</div>
|
||||
@if (SashDimEditList.Contains(IndexSash))
|
||||
{
|
||||
<div class="d-flex justify-content-start align-items-center mb-2">
|
||||
<div class="col-md-12 col-lg-7 d-grid px-0 justify-content-md-start">
|
||||
<h6 class="fw-bold text-nowrap">@Traduci("CWAreaS_Sash") @(CurrSashGroup.SashList.Count == 1 ? "" : (IndexSash + 1))</h6>
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-2 px-0">
|
||||
@if (!BaseUser && !(CurrAnta.AreaList[0] is Split))
|
||||
{
|
||||
<div class="col-md-4">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => AddSplitToSash()">@Traduci("CWAreaS_AddSplit")</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-2 px-0">
|
||||
@if (!BaseUser && CurrAnta.AreaList[0].AreaList.Count == 0)
|
||||
{
|
||||
<div class="col-md-4 px-2">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => AddInglesinaToSash()">@Traduci("CWAreaS_AddInglesina")</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-1 px-0">
|
||||
<button type="button" class="btn-close" aria-label="Close" @onclick="() => ClosePopup(IndexSash)"></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row align-items-center justify-content-start">
|
||||
<div class="col-lg-2 col-md-12 my-2">
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="btn btn-outline-secondary d-flex align-items-center gap-2"
|
||||
type="button"
|
||||
style="background-color: @(isOpenDropdown ? "#f8f9fa" : "#ffffff"); color: @(isOpenDropdown ? "#333333" : "");">
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="dropdown" @onfocusout="HandleFocusOut" tabindex="0">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle d-flex align-items-center gap-2"
|
||||
type="button"
|
||||
@onclick="ToggleDropdownOpening"
|
||||
aria-expanded="@isOpenDropdown">
|
||||
<span class="d-flex align-items-center">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(CurrOpening)" title="@(CurrOpening)" width="50" />
|
||||
</span>
|
||||
</button>
|
||||
<ul class="dropdown-menu p-2 @(isOpenDropdown ? "show" : "")"
|
||||
style="position: absolute; min-width: 20em;">
|
||||
<div class="row g-2 row-cols-4 m-0">
|
||||
@foreach (var openingType in CurrSashDim.OpeningTypeList)
|
||||
{
|
||||
<div class="col p-0">
|
||||
<button type="button"
|
||||
class="dropdown-item d-flex flex-column align-items-center justify-content-center p-2 rounded text-center h-100 @ButtonOpeningCss(openingType.Id)"
|
||||
@onclick="() => SelOpeningSash(openingType.Id, openingType.Name)">
|
||||
<img class="img-fluid" src="@GetImageOpeningPath(openingType.Name)"
|
||||
title="@(openingType.Name)" width="100" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-5 col-md-12 my-2">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWAreaS_Dimension")</span>
|
||||
@if(BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@Dimension">
|
||||
@switch (CurrSashDim.SelMeasureType.ToString())
|
||||
{
|
||||
case "ABSOLUTE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">mm</span>
|
||||
break;
|
||||
}
|
||||
case "PROPORTIONAL":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">*</span>
|
||||
break;
|
||||
}
|
||||
case "PERCENTAGE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@Dimension">
|
||||
<select class="form-select" style="max-width:6rem; background-color:#e9ecef" @bind="@MeasureTypeIndex">
|
||||
@foreach (var mType in CurrSashDim.MeasureTypeList)
|
||||
{
|
||||
<option value=@(mType.Id)>
|
||||
@switch (mType.Name)
|
||||
{
|
||||
case "Absolute":
|
||||
{
|
||||
<span class="input-group-text">mm</span>
|
||||
break;
|
||||
}
|
||||
case "Proportional":
|
||||
{
|
||||
<span class="input-group-text">*</span>
|
||||
break;
|
||||
}
|
||||
case "Percentage":
|
||||
{
|
||||
<span class="input-group-text">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-md-12 my-2">
|
||||
<div class="d-flex justify-content-start fs-5 mb-2">
|
||||
@if(BaseUser)
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" disabled="disabled" type="checkbox" name="Handle" checked="@CurrSashDim.bHasHandle">
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto" type="checkbox" name="Handle" checked="@CurrSashDim.bHasHandle" @onclick="() => ChangeHandle()">
|
||||
</div>
|
||||
}
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWAreaS_Handle")</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-12">
|
||||
<div class="row justify-content-between align-items-center pb-2" style="min-height: 2.5rem;">
|
||||
<div class="col-md-4 d-flex justify-content-start align-items-center">
|
||||
<h6>@Traduci("CWAreaS_Joints")</h6>
|
||||
<div class="d-flex align-items-center pb-2" style="min-height: 2.5rem;">
|
||||
<h6 class="mb-0">@Traduci("CWAreaS_Joints")</h6>
|
||||
<div class="d-flex gap-1 ms-auto">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-0 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_H) mx-1 px-0 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full H")" title="Full H" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-0 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-0 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.ANGLED)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_H) mx-1 px-0 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.FULL_H)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full H")" title="Full H" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-0 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.FULL_V)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
}
|
||||
</div>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="col-md-8 d-flex justify-content-end align-items-center">
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_H) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full H")" title="Full H" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="col-md-8 d-flex justify-content-end align-items-center">
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-1 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.ANGLED)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_H) mx-1 px-1 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.FULL_H)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full H")" title="Full H" width="40" />
|
||||
</button>
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-1 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.FULL_V)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="row g-3">
|
||||
@* Joint top left e joint top right *@
|
||||
@@ -363,10 +216,8 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-12">
|
||||
<div class="row justify-content-between align-items-center mb-4" style="min-height: 2.5rem;">
|
||||
<div class="col d-flex justify-content-start align-items-center">
|
||||
<h6>@Traduci("CWAreaS_Element")</h6>
|
||||
</div>
|
||||
<div class="d-flex align-items-center mb-4" style="min-height: 2.5rem;">
|
||||
<h6 class="mb-0">@Traduci("CWAreaS_Element")</h6>
|
||||
</div>
|
||||
<div class="row g-3">
|
||||
@foreach (var element in CurrSashDim.ElementDimensionList)
|
||||
|
||||
@@ -487,7 +487,7 @@ namespace WebWindowComplex.Compo
|
||||
{
|
||||
// Un piccolo delay assicura che l'evento @onclick dell'item venga eseguito prima di chiudere il menu
|
||||
await Task.Delay(150);
|
||||
isOpen = false;
|
||||
isOpenDropdown = false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,55 +1,41 @@
|
||||
<div class="card shadow-sm rounded">
|
||||
<div class="card-body py-2">
|
||||
<div class="d-flex justify-content-between align-items-center mt-2">
|
||||
<div class="col-4 d-flex justify-content-left">
|
||||
<h5>@Traduci("CWAreaSp_AreaSp") @(SplittedList.Count > 1 ? (SplittedList.IndexOf(CurrSplitted) + 1) : "")</h5>
|
||||
</div>
|
||||
<div class="col d-flex justify-content-center">
|
||||
<div class="d-flex align-items-center mt-2">
|
||||
<h5>@Traduci("CWAreaSp_AreaSp") @(SplittedList.Count > 1 ? (SplittedList.IndexOf(CurrSplitted) + 1) : "")</h5>
|
||||
<div class="d-flex g-2 ms-auto">
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RaiseAddSash()">@Traduci("CWAreaSp_AddSash")</button>
|
||||
</div>
|
||||
</div>
|
||||
@if (SashGroupList.Count == 1)
|
||||
{
|
||||
<div class="col d-flex justify-content-center">
|
||||
@if (SashGroupList.Count == 1)
|
||||
{
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RaiseCopySash(0)">@Traduci("CWAreaSp_CopySash")</button>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
else if (SashGroupList.Count > 1)
|
||||
{
|
||||
<div class="dropdown px-4">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle btn-sm"
|
||||
type="button"
|
||||
@onclick="ToggleDropdown"
|
||||
aria-expanded="@isOpen">
|
||||
@Traduci("CWAreaSp_CopySash")
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpen ? "show" : "")"
|
||||
style="min-width:0rem; max-width:10rem">
|
||||
@for (int indexCurrSash = 0; indexCurrSash <= SashGroupList.Count - 1; indexCurrSash++)
|
||||
{
|
||||
int IndexCopy = indexCurrSash;
|
||||
<li>
|
||||
<button class="dropdown-item" @onclick="() => RaiseCopySash(IndexCopy)">
|
||||
@Traduci("CWAreaSp_Sash") @(IndexCopy + 1)
|
||||
</button>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
@* @for (int j = 0; j < SashGroupList.Count; j++)
|
||||
{
|
||||
|
||||
int Index = j;
|
||||
<div class="col d-flex justify-content-center">
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RaiseCopySash(Index)">@Traduci("CWAreaSp_CopySash") @(SashGroupList.Count == 1 ? "" : (Index + 1))</button>
|
||||
}
|
||||
else if (SashGroupList.Count > 1)
|
||||
{
|
||||
<div class="dropdown px-4">
|
||||
<button class="btn btn-outline-secondary dropdown-toggle btn-sm"
|
||||
type="button"
|
||||
@onclick="ToggleDropdown"
|
||||
aria-expanded="@isOpen">
|
||||
@Traduci("CWAreaSp_CopySash")
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpen ? "show" : "")"
|
||||
style="min-width:0rem; max-width:10rem">
|
||||
@for (int indexCurrSash = 0; indexCurrSash <= SashGroupList.Count - 1; indexCurrSash++)
|
||||
{
|
||||
int IndexCopy = indexCurrSash;
|
||||
<li>
|
||||
<button class="dropdown-item" @onclick="() => RaiseCopySash(IndexCopy)">
|
||||
@Traduci("CWAreaSp_Sash") @(IndexCopy + 1)
|
||||
</button>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
} *@
|
||||
}
|
||||
</div>
|
||||
<div class="col d-flex justify-content-center">
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RaiseAddInglesina()">@Traduci("CWAreaSp_AddInglesina")</button>
|
||||
|
||||
@@ -19,11 +19,11 @@
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="@buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWFill_Glass")</button>
|
||||
<button class="btn-icone @buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWFill_Glass")</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="@buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)" @onclick="() => ChangeOneFill(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWFill_Glass")</button>
|
||||
<button class="btn-icone @buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)" @onclick="() => ChangeOneFill(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWFill_Glass")</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
@@ -31,11 +31,11 @@
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="@buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWFill_Wood")</button>
|
||||
<button class="btn-icone @buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWFill_Wood")</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="@buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)" @onclick="() => ChangeOneFill(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWFill_Wood")</button>
|
||||
<button class="btn-icone @buttonFillCss(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)" @onclick="() => ChangeOneFill(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWFill_Wood")</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -99,7 +99,7 @@ namespace WebWindowComplex.Compo
|
||||
/// <returns></returns>
|
||||
private string buttonFillCss(FillTypes reqFillTypes)
|
||||
{
|
||||
return (CurrFill.SelFillType == reqFillTypes) ? "btn btn-secondary btn-sm" : "btn btn-outline-secondary btn-sm";
|
||||
return (CurrFill.SelFillType == reqFillTypes) ? "active" : "";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
/* Stato Normale (Non Attivo) */
|
||||
.btn-icone {
|
||||
background-color: #ffffff;
|
||||
border: 2px solid #d1d5db; /* Bordo grigio tenue di media visibilità */
|
||||
box-shadow: 0 4px 12px rgba(212, 230, 250, 0.8); /* Ombra azzurra delicata */
|
||||
font-weight: 400;
|
||||
padding: 10px 22px;
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
transition: transform 0.2s ease, background-color 0.2s ease, border 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
|
||||
}
|
||||
|
||||
/* Hover (Passaggio del mouse - si applica in tutti gli stati) */
|
||||
.btn-icone:hover {
|
||||
transform: scale(1.08); /* Ingrandimento del bottone */
|
||||
border-color: #9ca3af; /* Bordo grigio leggermente più nitido all'hover */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35); /* Ombra blu leggermente più intensa */
|
||||
}
|
||||
|
||||
/* Stato Attivo (Selezionato) */
|
||||
.btn-icone.active {
|
||||
background-color: #ffffff; /* Sfondo bianco */
|
||||
border: 3px solid #a6ccf5; /* Bordo azzurro */
|
||||
box-shadow: 0 2px 8px rgba(2, 132, 199, 0.2);
|
||||
}
|
||||
|
||||
/* Hover specifico quando il bottone è Attivo */
|
||||
.btn-icone.active:hover {
|
||||
transform: scale(1.08);
|
||||
background-color: #ffffff; /* Azzurro leggermente più carico al passaggio */
|
||||
border-color: #a6ccf5; /* Sottile affinamento del bordo */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35);
|
||||
}
|
||||
|
||||
/* Effetto Pressione al Click (Mouse premuto) */
|
||||
.btn-icone:active,
|
||||
.btn-icone.active:active {
|
||||
transform: scale(0.96) translateY(2px);
|
||||
box-shadow: 0 2px 4px rgba(212, 230, 250, 0.15);
|
||||
transition: transform 0.05s ease, box-shadow 0.05s ease;
|
||||
}
|
||||
@@ -16,21 +16,18 @@
|
||||
<div class="col-md-12 col-lg-12">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_Shape")</h6>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_Shape")</h6>
|
||||
</div>
|
||||
@* <input type="text" readonly class="form-control" value="@(CurrFrameWindow.ShapeList.ElementAt(SelShapeIndex - 1))"> *@
|
||||
<div class="row">
|
||||
@foreach (var i in CurrFrameWindow.ShapeList)
|
||||
{
|
||||
<div class="col-auto">
|
||||
<button type="button" class="btn-iconeOff @ButtonShapeCss(i.Id) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageFrameShapePath(i.Name)" title="@(i.Name)" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@foreach (var i in CurrFrameWindow.ShapeList)
|
||||
{
|
||||
<div class="col-auto my-1">
|
||||
<button type="button" class="btn-iconeOff @ButtonShapeCss(i.Id) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageFrameShapePath(i.Name)" title="@(i.Name)" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
else
|
||||
@@ -41,7 +38,7 @@
|
||||
<div class="row">
|
||||
@foreach (var i in CurrFrameWindow.ShapeList)
|
||||
{
|
||||
<div class="col-auto">
|
||||
<div class="col-auto my-1">
|
||||
<button type="button" class="btn-icone @ButtonShapeCss(i.Id) mx-1 px-1 py-1" @onclick="() => SelShapeFrame(i.Id)">
|
||||
<img class="img-fluid" src="@GetImageFrameShapePath(i.Name)" title="@(i.Name)" width="40" />
|
||||
</button>
|
||||
@@ -70,17 +67,15 @@
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_Threshold")</h6>
|
||||
<h6 class="fw-bold text-start">@Traduci("CWFrame_Threshold")</h6>
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<span class="input-group-text">@Traduci("CWFrame_Tipology")</span>
|
||||
<input type="text" readonly class="form-control" value="@(CurrFrameWindow.ThresholdList.FirstOrDefault(x => x.Type == SelThreshold)?.Name)">
|
||||
}
|
||||
else
|
||||
{
|
||||
<label class="input-group-text">@Traduci("CWFrame_Tipology")</label>
|
||||
<select class="form-select" @bind="SelThreshold">
|
||||
@foreach (var item in CurrFrameWindow.ThresholdList)
|
||||
{
|
||||
@@ -93,9 +88,7 @@
|
||||
<div class="col-md-12 col-lg-6">
|
||||
@if (SashNotInBottom())
|
||||
{
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_BottomRail")</h6>
|
||||
</div>
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_BottomRail")</h6>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWFrame_Quantity")</span>
|
||||
@if (BaseUser)
|
||||
@@ -117,13 +110,11 @@
|
||||
<hr />
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="row justify-content-between align-items-center pb-2" style="min-height: 2.5rem;">
|
||||
<div class="col-md-4 d-flex justify-content-start align-items-center">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_Joints")</h6>
|
||||
</div>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="col-md-8 d-flex justify-content-end align-items-center">
|
||||
<div class="d-flex align-items-center pb-2" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold mb-0">@Traduci("CWFrame_Joints")</h6>
|
||||
<div class="d-flex gap-1 ms-auto">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button type="button" class="btn-iconeOff @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
@@ -133,11 +124,9 @@
|
||||
<button type="button" class="btn-iconeOff @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="col-md-8 d-flex justify-content-end align-items-center">
|
||||
}
|
||||
else
|
||||
{
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.ANGLED) mx-1 px-1 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.ANGLED)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Angled")" title="Angled" width="40" />
|
||||
</button>
|
||||
@@ -147,31 +136,29 @@
|
||||
<button type="button" class="btn-icone @ButtonJointCss(Json.WindowConst.Joints.FULL_V) mx-1 px-1 py-1" @onclick="() => ChangeAllJoints(WebWindowComplex.Json.WindowConst.Joints.FULL_V)">
|
||||
<img class="img-fluid" src="@GetImageJointShapePath("Full V")" title="Full V" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row g-3">
|
||||
@* Joint top left e joint top right *@
|
||||
@for (int i = CurrFrameWindow.JointList.Count - 1; i >= 2; i--)
|
||||
{
|
||||
<div class="col-6">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<EditJoint CurrRec="CurrFrameWindow.JointList.ElementAt(i)" EC_Update="UpdateJoint"></EditJoint>
|
||||
</div>
|
||||
}
|
||||
@* Joint bottom left e joint bottom right *@
|
||||
<div class="col-6">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<EditJoint CurrRec="CurrFrameWindow.JointList.ElementAt(0)" EC_Update="UpdateJoint"></EditJoint>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<EditJoint CurrRec="CurrFrameWindow.JointList.ElementAt(1)" EC_Update="UpdateJoint"></EditJoint>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="row justify-content-between align-items-center mb-4" style="min-height: 2.5rem;">
|
||||
<div class="col d-flex justify-content-start align-items-center">
|
||||
<h6 class="fw-bold">@Traduci("CWFrame_Element")</h6>
|
||||
</div>
|
||||
<div class="d-flex align-items-center mb-4" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold mb-0">@Traduci("CWFrame_Element")</h6>
|
||||
</div>
|
||||
<div class="row g-3">
|
||||
@foreach (var element in CurrFrameWindow.ElementDimensionList)
|
||||
|
||||
@@ -95,8 +95,12 @@ namespace WebWindowComplex.Compo
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private Dictionary<string, string> FrameDict = new();
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Properties
|
||||
private string GetImageFrameShapePath(string fileName) => $"_content/Egw.Lux.WebWindowComplex/icone/frame/shape/{fileName}.svg";
|
||||
private string GetImageJointShapePath(string fileName) => $"_content/Egw.Lux.WebWindowComplex/icone/joint/shape/All/{fileName}.svg";
|
||||
|
||||
@@ -3,104 +3,114 @@
|
||||
<div class="card shadow-sm rounded mb-4">
|
||||
<div class="card-header bg-light bg-opacity-25">
|
||||
<div class="d-flex justify-content-between align-items-center">
|
||||
<div class="px-2">
|
||||
<h5>@(descParentInglesina())</h5>
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<button class="btn btn-close" @onclick="ReqClose"></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body py-2">
|
||||
<div class="d-flex justify-content-end align-items-center">
|
||||
<div class="col-md-3">
|
||||
<select class="form-select" @bind="@MeasureType">
|
||||
<option value="@MeasureTypes.ABSOLUTE">Absolute (mm)</option>
|
||||
<option value="@MeasureTypes.PROPORTIONAL">Proportional (*)</option>
|
||||
<option value="@MeasureTypes.PERCENTAGE">Percentage (%)</option>
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="d-flex gap-2 ms-auto">
|
||||
<select class="form-select w-auto" @bind="@MeasureType">
|
||||
<option value="@MeasureTypes.ABSOLUTE">@Traduci("CWIng_Absolute") (mm)</option>
|
||||
<option value="@MeasureTypes.PROPORTIONAL">@Traduci("CWIng_Proportional") (*)</option>
|
||||
<option value="@MeasureTypes.PERCENTAGE">@Traduci("CWIng_Percentage") (%)</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<select class="form-select">
|
||||
<option value="1">Glass</option>
|
||||
<select class="form-select w-auto">
|
||||
<option value="1">@Traduci("CWIng_Glass")</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-start align-items-center py-2">
|
||||
<div class="col-lg-2 justify-content-start">
|
||||
<h5>Inglesina</h5>
|
||||
<div class="row justify-content-start">
|
||||
<div class="col-4 text-start">
|
||||
<h5>@Traduci("CWIng_Inglesina")</h5>
|
||||
</div>
|
||||
@if (!BaseUser)
|
||||
{
|
||||
<div class="col-lg-10 justify-content-start">
|
||||
<div class="col-md-3">
|
||||
<div class="input-group">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RemoveArea()">Remove inglesina</button>
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RemoveArea()">@Traduci("CWIng_RemoveIng")</button>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<span class="input-group-text">Shape</span>
|
||||
<input type="text" readonly class="form-control" value="@(CurrInglesina.SplitShapeList.FirstOrDefault(x => x.Id == InglesinaShapeIndex))">
|
||||
}
|
||||
else
|
||||
{
|
||||
<label class="input-group-text">Shape</label>
|
||||
<select class="form-select" @bind="@InglesinaShapeIndex">
|
||||
@foreach (var shapeType in CurrInglesina.SplitShapeList)
|
||||
{
|
||||
<option value=@(shapeType.Id)>@(shapeType.Name)</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
<div class="row py-2">
|
||||
<div class="col-md-12 col-lg-12">
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWIng_Shape")</h6>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<span class="input-group-text">Side</span>
|
||||
<input type="text" readonly class="form-control" value="@(CurrInglesina.SideList.FirstOrDefault(x => x.Id == SideIndex))">
|
||||
}
|
||||
else
|
||||
{
|
||||
<label class="input-group-text">Side</label>
|
||||
<select class="form-select" @bind="@SideIndex">
|
||||
@foreach (var sideType in CurrInglesina.SideList)
|
||||
{
|
||||
<option value=@(sideType.Id)>@(sideType.Name)</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@if (CurrInglesina.nSplitQtyVert > 0)
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">QtyVert</span>
|
||||
@if (BaseUser)
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="row align-items-center mb-2">
|
||||
@foreach (var i in CurrInglesina.SplitShapeList)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@InglesinaQtyVert">
|
||||
<div class="col-auto">
|
||||
<button type="button" class="btn-icone @ButtonShapeCss(i.Id) mx-1 px-1 py-1">
|
||||
<img class="img-fluid" src="@GetImageShapePath(i.Name)" title="@Traduci("CWIng_" + i.Name)" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
<div class="col-auto">
|
||||
<div class="form-floating">
|
||||
<input type="text" readonly class="form-control" value="@(CurrInglesina.SideList.FirstOrDefault(x => x.Id == SideIndex))">
|
||||
<label>@Traduci("CWIng_Side")</label>
|
||||
</div>
|
||||
</div>
|
||||
@if (CurrInglesina.SelSplitShape == Json.WindowConst.SplitShapes.GRID)
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@InglesinaQtyVert">
|
||||
<div class="col-auto align-items-center">
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto me-1" type="checkbox" checked="@CurrInglesina.bSplitStartVert" @onclick:preventDefault>
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWIng_StartVert")</label>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@if (CurrInglesina.nSplitQtyHoriz > 0)
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="row align-items-center">
|
||||
@foreach (var i in CurrInglesina.SplitShapeList)
|
||||
{
|
||||
<div class="col-auto">
|
||||
<button type="button" class="btn-icone @ButtonShapeCss(i.Id) mx-1 px-1 py-1" @onclick="() => SelShapeInglesina(i.Id)">
|
||||
<img class="img-fluid" src="@GetImageShapePath(i.Name)" title="@Traduci("CWIng_" + i.Name)" width="40" />
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
<div class="col-3">
|
||||
<div class="form-floating">
|
||||
<select class="form-select" @bind="@SideIndex">
|
||||
@foreach (var sideType in CurrInglesina.SideList)
|
||||
{
|
||||
<option value=@(sideType.Id)>@Traduci("CWIng_" + sideType.Name)</option>
|
||||
}
|
||||
</select>
|
||||
<label>@Traduci("CWIng_Side")</label>
|
||||
</div>
|
||||
</div>
|
||||
@if (CurrInglesina.SelSplitShape == Json.WindowConst.SplitShapes.GRID)
|
||||
{
|
||||
<div class="col-auto">
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto me-1" type="checkbox" checked="@CurrInglesina.bSplitStartVert" @oninput="(ChangeEventArgs e) => ChangeStartVert(e)">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWIng_StartVert")</label>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
@if (CurrInglesina.nSplitQtyHoriz > 0)
|
||||
{
|
||||
<hr />
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWIng_HorizIng")</h6>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">QtyHoriz</span>
|
||||
<span class="input-group-text">@Traduci("CWIng_QtyElem")</span>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@InglesinaQtyHoriz">
|
||||
@@ -111,103 +121,67 @@
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
<div class="row">
|
||||
@if (CurrInglesina.SplitVertList.Count > 0 && CurrInglesina.SplitHorizList.Count > 0)
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
@for (int i = 0; i < CurrInglesina.SplitVertList.Count; i++)
|
||||
{
|
||||
<EditSplitDimensions CurrRec="CurrInglesina.SplitVertList[i]"
|
||||
Name="Width"
|
||||
Index="i"
|
||||
EC_Update="UpdateDimension">
|
||||
</EditSplitDimensions>
|
||||
}
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-6">
|
||||
@for (int i = 0; i < CurrInglesina.SplitHorizList.Count; i++)
|
||||
{
|
||||
<EditSplitDimensions CurrRec="CurrInglesina.SplitHorizList[i]"
|
||||
Name="Height"
|
||||
Index="i"
|
||||
EC_Update="UpdateDimension">
|
||||
</EditSplitDimensions>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
else if (CurrInglesina.SplitHorizList.Count > 0)
|
||||
{
|
||||
</div>
|
||||
<div class="row">
|
||||
@for (int i = 0; i < CurrInglesina.SplitHorizList.Count; i++)
|
||||
{
|
||||
<EditSplitDimensions CurrRec="CurrInglesina.SplitHorizList[i]"
|
||||
Name="Height"
|
||||
Index="i"
|
||||
TotElem="CurrInglesina.SplitHorizList.Count"
|
||||
EC_Update="UpdateDimension">
|
||||
</EditSplitDimensions>
|
||||
}
|
||||
}
|
||||
else if (CurrInglesina.SplitVertList.Count > 0)
|
||||
{
|
||||
</div>
|
||||
<div class="row">
|
||||
@foreach (var element in horizList())
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<EditSplitElement CurrRec="element" Type="Horizontal" EC_Update="UpdateElement"></EditSplitElement>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (CurrInglesina.nSplitQtyVert > 0)
|
||||
{
|
||||
<hr />
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWIng_VerticalIng")</h6>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWIng_QtyElem")</span>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@InglesinaQtyVert">
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@InglesinaQtyVert">
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@for (int i = 0; i < CurrInglesina.SplitVertList.Count; i++)
|
||||
{
|
||||
<EditSplitDimensions CurrRec="CurrInglesina.SplitVertList[i]"
|
||||
Name="Width"
|
||||
Index="i"
|
||||
TotElem="CurrInglesina.SplitVertList.Count"
|
||||
EC_Update="UpdateDimension">
|
||||
</EditSplitDimensions>
|
||||
}
|
||||
}
|
||||
</div>
|
||||
@if (CurrInglesina.SelSplitShape == Json.WindowConst.SplitShapes.GRID)
|
||||
{
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="d-flex justify-content-start fs-5 mb-2">
|
||||
<div class="px-1">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<input class="form-check-input ml-auto" disabled="disabled" type="checkbox" name="SplitStartVert" checked="@CurrInglesina.bSplitStartVert">
|
||||
}
|
||||
else
|
||||
{
|
||||
<input class="form-check-input ml-auto" type="checkbox" name="SplitStartVert" checked="@CurrInglesina.bSplitStartVert" @oninput="(ChangeEventArgs e) => ChangeStartVert(e)">
|
||||
}
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<label class="form-check-label fs-6 text-dark">StartVert</label>
|
||||
</div>
|
||||
@foreach (var element in vertList())
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<EditSplitElement CurrRec="element" Type="Vertical" EC_Update="UpdateElement"></EditSplitElement>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
<hr/>
|
||||
<div class="row">
|
||||
@if (CurrInglesina.nSplitQtyVert > 0)
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="d-flex justify-content-start align-items-center px-2">
|
||||
<h6>Element vert</h6>
|
||||
</div>
|
||||
@foreach (var element in vertList())
|
||||
{
|
||||
<EditSplitElement CurrRec="element" EC_Update="UpdateElement"></EditSplitElement>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (CurrInglesina.nSplitQtyHoriz > 0)
|
||||
{
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="d-flex justify-content-start align-items-center px-2">
|
||||
<h6>Element horiz</h6>
|
||||
</div>
|
||||
@foreach (var element in horizList())
|
||||
{
|
||||
<EditSplitElement CurrRec="element" EC_Update="UpdateElement"></EditSplitElement>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -70,60 +70,42 @@ namespace WebWindowComplex.Compo
|
||||
public EventCallback<bool> EC_ReqClose { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per rimuovere Inglesina
|
||||
/// Vocabolario con traduzione lingua corrente
|
||||
/// </summary>
|
||||
/// <param name="item"> Inglesina corrente </param>
|
||||
/// <returns></returns>
|
||||
protected async Task RemoveArea()
|
||||
[CascadingParameter(Name = "Vocabulary")]
|
||||
public Dictionary<string, string> Vocabulary { get; set; } = null!;
|
||||
|
||||
#region Protected Properties
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
CurrInglesina.Remove();
|
||||
var args = new DataUpdateFrame()
|
||||
{
|
||||
currFrame = FrameWindow
|
||||
};
|
||||
// richiesta reset dict shape
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_UpdateFrame.InvokeAsync(args);
|
||||
await EC_ReqClose.InvokeAsync(true);
|
||||
InglesinaDict = Vocabulary.Where(x => x.Key.Contains("CWIng_")).ToDictionary(x => x.Key, y => y.Value);
|
||||
}
|
||||
|
||||
#endregion Protected Properties
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private Dictionary<string, string> InglesinaDict = new();
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Properties
|
||||
|
||||
/// <summary>
|
||||
/// Proprietà per selezionare shape Inglesina
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected int InglesinaShapeIndex
|
||||
private int InglesinaShapeIndex
|
||||
{
|
||||
get => CurrInglesina.SelSplitShapeIndex;
|
||||
set
|
||||
{
|
||||
if (CurrInglesina.SelSplitShapeIndex != value)
|
||||
{
|
||||
CurrInglesina.SelSplitShapeIndex = value;
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
_ = EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = LayoutConst.DataAction.ResetDimElem });
|
||||
if(!(CurrInglesina.ParentArea.ParentArea is Sash))
|
||||
{
|
||||
// Se la shape selezionata è grid o custom, richiede reset shape
|
||||
if (value == (int)SplitShapes.GRID || value == (int)SplitShapes.CUSTOM)
|
||||
_ = EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
if (SearchSash(CurrInglesina))
|
||||
_ = EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetHwOpt });
|
||||
}
|
||||
_ = EC_ReqElement.InvokeAsync(CurrInglesina);
|
||||
_ = EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Proprietà per selezionare shape Inglesina
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected int SideIndex
|
||||
private int SideIndex
|
||||
{
|
||||
get => CurrInglesina.SelSideIndex;
|
||||
set
|
||||
@@ -142,20 +124,11 @@ namespace WebWindowComplex.Compo
|
||||
}
|
||||
}
|
||||
|
||||
private bool SearchSash(Area area)
|
||||
{
|
||||
if (area is Sash)
|
||||
return true;
|
||||
foreach (var item in area.AreaList)
|
||||
return SearchSash(item);
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Proprietà per selezionare numero di Inglesina verticali
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected int InglesinaQtyVert
|
||||
private int InglesinaQtyVert
|
||||
{
|
||||
get => CurrInglesina.nSplitQtyVert;
|
||||
set
|
||||
@@ -178,7 +151,7 @@ namespace WebWindowComplex.Compo
|
||||
/// Proprietà per selezionare numero di Inglesina verticali
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected int InglesinaQtyHoriz
|
||||
private int InglesinaQtyHoriz
|
||||
{
|
||||
get => CurrInglesina.nSplitQtyHoriz;
|
||||
set
|
||||
@@ -197,149 +170,7 @@ namespace WebWindowComplex.Compo
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Aggiornamento element
|
||||
/// </summary>
|
||||
/// <param name="updRec"></param>
|
||||
/// <returns></returns>
|
||||
private async Task UpdateElement(SplitElementDimension updRec)
|
||||
{
|
||||
if (updRec != null)
|
||||
{
|
||||
SplitElementDimension? currRec = new SplitElementDimension(updRec.ParentArea, 0,0,-1);
|
||||
if (updRec.nSubArea != 0)
|
||||
{
|
||||
List<SplitElementDimension> ElemIndexList = new List<SplitElementDimension>();
|
||||
if (CurrInglesina.bSplitStartVert)
|
||||
ElemIndexList = CurrInglesina.ElemDimHorizList
|
||||
.Where(x => x.nSubArea != updRec.nSubArea && x.nIndex == updRec.nIndex)
|
||||
.ToList();
|
||||
else
|
||||
ElemIndexList = CurrInglesina.ElemDimVertList
|
||||
.Where(x => x.nSubArea == updRec.nSubArea && x.nIndex == updRec.nIndex)
|
||||
.ToList();
|
||||
foreach (var item in ElemIndexList)
|
||||
{
|
||||
item.SetDimension(updRec.dDimension);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if(CurrInglesina.bSplitStartVert)
|
||||
currRec = CurrInglesina.ElemDimVertList.FirstOrDefault(x => x.ParentArea == updRec.ParentArea && x.nIndex == updRec.nIndex);
|
||||
else
|
||||
currRec = CurrInglesina.ElemDimHorizList.FirstOrDefault(x => x.ParentArea == updRec.ParentArea && x.nIndex == updRec.nIndex);
|
||||
// lo aggiorno
|
||||
currRec = updRec;
|
||||
}
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per aggiornare la dimensione dell'3Inglesina
|
||||
/// </summary>
|
||||
/// <param name="updRec"></param>
|
||||
/// <returns></returns>
|
||||
protected async Task UpdateDimension(DataUpdateSplitDimension updRec)
|
||||
{
|
||||
SplitDimension currSplitDim = updRec.currSplit;
|
||||
SplitDimension currRec = new SplitDimension(0, MeasureTypes.NULL, false, updRec.currSplit.Parent, false);
|
||||
// cerco il record
|
||||
if (currSplitDim.bIsVertListDim)
|
||||
currRec = CurrInglesina.SplitVertList.ElementAt(updRec.index);
|
||||
else
|
||||
currRec = CurrInglesina.SplitHorizList.ElementAt(updRec.index);
|
||||
// lo aggiorno
|
||||
if (currSplitDim != null)
|
||||
{
|
||||
currRec = currSplitDim;
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina,
|
||||
noSvg = updRec.noSvg
|
||||
};
|
||||
//await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per cambiare la dimensione principale
|
||||
/// </summary>
|
||||
/// <param name="e"></param>
|
||||
/// <returns></returns>
|
||||
protected async Task ChangeStartVert(ChangeEventArgs e)
|
||||
{
|
||||
foreach (Split s in InglesinaList)
|
||||
{
|
||||
if (s.Equals(CurrInglesina) && e.Value != null)
|
||||
{
|
||||
s.bSplitStartVert = (bool)e.Value;
|
||||
//s.SetSplitStartVert((bool)e.Value);
|
||||
}
|
||||
}
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDimElem });
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
await EC_ReqElement.InvokeAsync(CurrInglesina);
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per determinare la descrizione del parent dello Inglesina corrente
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
protected string descParentInglesina()
|
||||
{
|
||||
if ((CurrInglesina.ParentArea.ParentArea is Splitted || CurrInglesina.ParentArea.ParentArea.ParentArea is Sash) && SashGroupList.Count > 0)
|
||||
{
|
||||
for (int j = 0; j < SashGroupList.Count; j++)
|
||||
{
|
||||
if (SashGroupList[j].Equals(CurrInglesina.ParentArea.ParentArea))
|
||||
{
|
||||
return "Sash " + (j + 1);
|
||||
}
|
||||
else if (SashGroupList[j].Equals(CurrInglesina.ParentArea.ParentArea.ParentArea))
|
||||
{
|
||||
for (int k = 0; k < SashGroupList[j].AreaList.Count; k++)
|
||||
{
|
||||
if (SashGroupList[j].AreaList[k].AreaList[0].AreaList.Count > 0 && SashGroupList[j].AreaList[k].AreaList[0].AreaList[0].Equals(CurrInglesina))
|
||||
{
|
||||
return "Sash group " + (j + 1) + " - sash " + (k + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return "Frame";
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sollevo evento per tornare alla pagina Tree
|
||||
/// </summary>
|
||||
private void ReqClose()
|
||||
{
|
||||
_ = EC_ReqClose.InvokeAsync(true);
|
||||
}
|
||||
|
||||
private bool isOpen = false;
|
||||
private void ToggleDropdown()
|
||||
{
|
||||
isOpen = !isOpen;
|
||||
}
|
||||
|
||||
protected MeasureTypes MeasureType
|
||||
private MeasureTypes MeasureType
|
||||
{
|
||||
get
|
||||
{
|
||||
@@ -381,58 +212,264 @@ namespace WebWindowComplex.Compo
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Private Properties
|
||||
|
||||
#region Private Methods
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per cambiare il tipo di misura di tutti gli SplitDimension
|
||||
/// Metodo per path immagine forma
|
||||
/// </summary>
|
||||
/// <param name="type"> nuovo tipo </param>
|
||||
/// <param name="fileName"></param>
|
||||
/// <returns></returns>
|
||||
protected Task SetMeasureType(MeasureTypes type)
|
||||
private string GetImageShapePath(string fileName) => $"_content/Egw.Lux.WebWindowComplex/icone/split/shape/{fileName}.svg";
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per rimuovere Inglesina
|
||||
/// </summary>
|
||||
/// <param name="item"> Inglesina corrente </param>
|
||||
/// <returns></returns>
|
||||
private async Task RemoveArea()
|
||||
{
|
||||
isOpen = !isOpen;
|
||||
foreach (var item in CurrInglesina.SplitVertList)
|
||||
CurrInglesina.Remove();
|
||||
var args = new DataUpdateFrame()
|
||||
{
|
||||
item.SelMeasureTypeIndex = (int)type;
|
||||
//item.SetSelMeasureType(type);
|
||||
}
|
||||
foreach (var item in CurrInglesina.SplitHorizList)
|
||||
{
|
||||
item.SelMeasureTypeIndex = (int)type;
|
||||
//item.SetSelMeasureType(type);
|
||||
}
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina,
|
||||
noSvg = true
|
||||
currFrame = FrameWindow
|
||||
};
|
||||
return EC_UpdateInglesina.InvokeAsync(args);
|
||||
// richiesta reset dict shape
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_UpdateFrame.InvokeAsync(args);
|
||||
await EC_ReqClose.InvokeAsync(true);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per cercare l'anta in cui è l'inglesina
|
||||
/// </summary>
|
||||
/// <param name="area"></param>
|
||||
/// <returns></returns>
|
||||
private bool SearchSash(Area area)
|
||||
{
|
||||
if (area is Sash)
|
||||
return true;
|
||||
foreach (var item in area.AreaList)
|
||||
return SearchSash(item);
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per selezionare la forma dell'inglesina
|
||||
/// </summary>
|
||||
/// <param name="newShapeIndex"></param>
|
||||
/// <returns></returns>
|
||||
private async Task SelShapeInglesina(int newShapeIndex)
|
||||
{
|
||||
if (CurrInglesina.SelSplitShapeIndex != newShapeIndex)
|
||||
{
|
||||
CurrInglesina.SelSplitShapeIndex = newShapeIndex;
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = LayoutConst.DataAction.ResetDimElem });
|
||||
if (!(CurrInglesina.ParentArea.ParentArea is Sash))
|
||||
{
|
||||
// Se la shape selezionata è grid o custom, richiede reset shape
|
||||
if (newShapeIndex == (int)SplitShapes.GRID || newShapeIndex == (int)SplitShapes.CUSTOM)
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
if (SearchSash(CurrInglesina))
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetHwOpt });
|
||||
}
|
||||
await EC_ReqElement.InvokeAsync(CurrInglesina);
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Aggiornamento element
|
||||
/// </summary>
|
||||
/// <param name="updRec"></param>
|
||||
/// <returns></returns>
|
||||
private async Task UpdateElement(SplitElementDimension updRec)
|
||||
{
|
||||
if (updRec != null)
|
||||
{
|
||||
SplitElementDimension? currRec = new SplitElementDimension(updRec.ParentArea, 0, 0, -1);
|
||||
if (updRec.nSubArea != 0)
|
||||
{
|
||||
List<SplitElementDimension> ElemIndexList = new List<SplitElementDimension>();
|
||||
if (CurrInglesina.bSplitStartVert)
|
||||
ElemIndexList = CurrInglesina.ElemDimHorizList
|
||||
.Where(x => x.nSubArea != updRec.nSubArea && x.nIndex == updRec.nIndex)
|
||||
.ToList();
|
||||
else
|
||||
ElemIndexList = CurrInglesina.ElemDimVertList
|
||||
.Where(x => x.nSubArea == updRec.nSubArea && x.nIndex == updRec.nIndex)
|
||||
.ToList();
|
||||
foreach (var item in ElemIndexList)
|
||||
{
|
||||
item.SetDimension(updRec.dDimension);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (CurrInglesina.bSplitStartVert)
|
||||
currRec = CurrInglesina.ElemDimVertList.FirstOrDefault(x => x.ParentArea == updRec.ParentArea && x.nIndex == updRec.nIndex);
|
||||
else
|
||||
currRec = CurrInglesina.ElemDimHorizList.FirstOrDefault(x => x.ParentArea == updRec.ParentArea && x.nIndex == updRec.nIndex);
|
||||
// lo aggiorno
|
||||
currRec = updRec;
|
||||
}
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per aggiornare la dimensione dell'3Inglesina
|
||||
/// </summary>
|
||||
/// <param name="updRec"></param>
|
||||
/// <returns></returns>
|
||||
private async Task UpdateDimension(DataUpdateSplitDimension updRec)
|
||||
{
|
||||
SplitDimension currSplitDim = updRec.currSplit;
|
||||
SplitDimension currRec = new SplitDimension(0, MeasureTypes.NULL, false, updRec.currSplit.Parent, false);
|
||||
// cerco il record
|
||||
if (currSplitDim.bIsVertListDim)
|
||||
currRec = CurrInglesina.SplitVertList.ElementAt(updRec.index);
|
||||
else
|
||||
currRec = CurrInglesina.SplitHorizList.ElementAt(updRec.index);
|
||||
// lo aggiorno
|
||||
if (currSplitDim != null)
|
||||
{
|
||||
currRec = currSplitDim;
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina,
|
||||
noSvg = updRec.noSvg
|
||||
};
|
||||
//await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDictShape });
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per cambiare la dimensione principale
|
||||
/// </summary>
|
||||
/// <param name="e"></param>
|
||||
/// <returns></returns>
|
||||
private async Task ChangeStartVert(ChangeEventArgs e)
|
||||
{
|
||||
foreach (Split s in InglesinaList)
|
||||
{
|
||||
if (s.Equals(CurrInglesina) && e.Value != null)
|
||||
{
|
||||
s.bSplitStartVert = (bool)e.Value;
|
||||
//s.SetSplitStartVert((bool)e.Value);
|
||||
}
|
||||
}
|
||||
await EC_ReqResetDict.InvokeAsync(new DataUpdateRes { req = DataAction.ResetDimElem });
|
||||
var args = new DataUpdateInglesina()
|
||||
{
|
||||
currInglesina = CurrInglesina
|
||||
};
|
||||
await EC_ReqElement.InvokeAsync(CurrInglesina);
|
||||
await EC_UpdateInglesina.InvokeAsync(args);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per determinare la descrizione del parent dello Inglesina corrente
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private string descParentInglesina()
|
||||
{
|
||||
if ((CurrInglesina.ParentArea.ParentArea is Splitted || CurrInglesina.ParentArea.ParentArea.ParentArea is Sash) && SashGroupList.Count > 0)
|
||||
{
|
||||
for (int j = 0; j < SashGroupList.Count; j++)
|
||||
{
|
||||
if (SashGroupList[j].Equals(CurrInglesina.ParentArea.ParentArea))
|
||||
{
|
||||
return Traduci("CWIng_Sash") + " " + (j + 1);
|
||||
}
|
||||
else if (SashGroupList[j].Equals(CurrInglesina.ParentArea.ParentArea.ParentArea))
|
||||
{
|
||||
for (int k = 0; k < SashGroupList[j].AreaList.Count; k++)
|
||||
{
|
||||
if (SashGroupList[j].AreaList[k].AreaList[0].AreaList.Count > 0 && SashGroupList[j].AreaList[k].AreaList[0].AreaList[0].Equals(CurrInglesina))
|
||||
{
|
||||
return Traduci("CWIng_SashGroup") + " " + (j + 1) + " - " + Traduci("CWIng_Sash") + " " + (k + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return "Frame";
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sollevo evento per tornare alla pagina Tree
|
||||
/// </summary>
|
||||
private void ReqClose()
|
||||
{
|
||||
_ = EC_ReqClose.InvokeAsync(true);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per lista degli elementi orizzontali
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private List<SplitElementDimension> horizList()
|
||||
{
|
||||
int subAreaMin = CurrInglesina.ElemDimHorizList.Min(x => x.nSubArea);
|
||||
return CurrInglesina.ElemDimHorizList.Where(x => x.nSubArea == subAreaMin).ToList();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per lista degli elementi verticali
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private List<SplitElementDimension> vertList()
|
||||
{
|
||||
int subAreaMin = CurrInglesina.ElemDimVertList.Min(x => x.nSubArea);
|
||||
return CurrInglesina.ElemDimVertList.Where(x => x.nSubArea == subAreaMin).ToList();
|
||||
}
|
||||
|
||||
private string MeasureTypeCss(MeasureTypes type)
|
||||
/// <summary>
|
||||
/// Metodo per la visualizzazione dei pulsanti shape
|
||||
/// </summary>
|
||||
/// <param name="index"></param>
|
||||
/// <returns></returns>
|
||||
private string ButtonShapeCss(int index)
|
||||
{
|
||||
for (int i = 0; i < CurrInglesina.SplitVertList.Count; i++)
|
||||
{
|
||||
if (!CurrInglesina.SplitVertList.ElementAt(i).MeasureType.Equals(type))
|
||||
return "btn btn-outline-secondary";
|
||||
}
|
||||
for (int i = 0; i < CurrInglesina.SplitHorizList.Count; i++)
|
||||
{
|
||||
if (!CurrInglesina.SplitHorizList.ElementAt(i).MeasureType.Equals(type))
|
||||
return "btn btn-outline-secondary";
|
||||
}
|
||||
return "btn btn-secondary";
|
||||
string ans = "";
|
||||
if (InglesinaShapeIndex == index)
|
||||
ans = "active";
|
||||
return ans;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per traduzione in lingua corrente
|
||||
/// </summary>
|
||||
/// <param name="lemma"></param>
|
||||
/// <returns></returns>
|
||||
private string Traduci(string lemma)
|
||||
{
|
||||
string ans = lemma;
|
||||
if (InglesinaDict != null && InglesinaDict.ContainsKey(lemma))
|
||||
{
|
||||
ans = InglesinaDict.GetValueOrDefault(lemma) ?? "";
|
||||
}
|
||||
return ans;
|
||||
}
|
||||
|
||||
#endregion Private Methods
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
/* Stato Normale (Non Attivo) */
|
||||
.btn-icone {
|
||||
background-color: #ffffff;
|
||||
border: 2px solid #d1d5db; /* Bordo grigio tenue di media visibilità */
|
||||
box-shadow: 0 4px 12px rgba(212, 230, 250, 0.8); /* Ombra azzurra delicata */
|
||||
font-weight: 600;
|
||||
padding: 10px 22px;
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
transition: transform 0.2s ease, background-color 0.2s ease, border 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
|
||||
}
|
||||
|
||||
/* Hover (Passaggio del mouse - si applica in tutti gli stati) */
|
||||
.btn-icone:hover {
|
||||
transform: scale(1.08); /* Ingrandimento del bottone */
|
||||
border-color: #9ca3af; /* Bordo grigio leggermente più nitido all'hover */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35); /* Ombra blu leggermente più intensa */
|
||||
}
|
||||
|
||||
/* Stato Attivo (Selezionato) */
|
||||
.btn-icone.active {
|
||||
background-color: #ffffff; /* Sfondo bianco */
|
||||
border: 3px solid #a6ccf5; /* Bordo azzurro */
|
||||
box-shadow: 0 2px 8px rgba(2, 132, 199, 0.2);
|
||||
}
|
||||
|
||||
/* Hover specifico quando il bottone è Attivo */
|
||||
.btn-icone.active:hover {
|
||||
transform: scale(1.08);
|
||||
background-color: #ffffff; /* Azzurro leggermente più carico al passaggio */
|
||||
border-color: #a6ccf5; /* Sottile affinamento del bordo */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35);
|
||||
}
|
||||
|
||||
/* Effetto Pressione al Click (Mouse premuto) */
|
||||
.btn-icone:active,
|
||||
.btn-icone.active:active {
|
||||
transform: scale(0.96) translateY(2px);
|
||||
box-shadow: 0 2px 4px rgba(212, 230, 250, 0.15);
|
||||
transition: transform 0.05s ease, box-shadow 0.05s ease;
|
||||
}
|
||||
@@ -4,20 +4,14 @@
|
||||
<div class="card shadow-sm rounded mb-4">
|
||||
<div class="card-header bg-light bg-opacity-25">
|
||||
<div class="d-flex justify-content-between align-items-center">
|
||||
<div class="px-2">
|
||||
<h5>@Traduci("CWSash_SashGoup") @(SashGroupList.Count > 1 ? (SashGroupList.IndexOf(CurrSashGroup) + 1) : "")</h5>
|
||||
</div>
|
||||
<h5 class="text-nowrap">@Traduci("CWSash_SashGoup") @(SashGroupList.Count > 1 ? (SashGroupList.IndexOf(CurrSashGroup) + 1) : "")</h5>
|
||||
@if (!BaseUser)
|
||||
{
|
||||
<div class="px-2">
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RemoveArea()">@Traduci("CWSash_RemoveSash")</button>
|
||||
</div>
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<button class="btn btn-outline-secondary btn-sm" @onclick="() => RemoveArea()">@Traduci("CWSash_RemoveSash")</button>
|
||||
</div>
|
||||
}
|
||||
<div class="px-2">
|
||||
<button class="btn btn-close" @onclick="ReqClose"></button>
|
||||
</div>
|
||||
<button class="btn btn-close" @onclick="ReqClose"></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body py-2">
|
||||
@@ -91,26 +85,23 @@
|
||||
<hr />
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-6">
|
||||
<div class="row justify-content-between align-items-center">
|
||||
<div class="col d-flex justify-content-start align-items-center">
|
||||
<h6 class="fw-bold">@Traduci("CWSash_Hardware")</h6>
|
||||
</div>
|
||||
<div class="row align-items-center">
|
||||
<h6 class="fw-bold text-start">@Traduci("CWSash_Hardware")</h6>
|
||||
</div>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWSash_Family")</span>
|
||||
<input type="text" readonly class="form-control" value="@CurrSashGroup.SelHardware.FamilyName">
|
||||
<div class="form-floating mb-2">
|
||||
<input type="text" class="form-control" value="@CurrSashGroup.SelHardware.FamilyName" readonly>
|
||||
<label>@Traduci("CWSash_Family")</label>
|
||||
</div>
|
||||
<div class="input-group mb-2">
|
||||
<span class="input-group-text">@Traduci("CWSash_Type")</span>
|
||||
<input type="text" readonly class="form-control" value="@CurrSashGroup.SelHardware.Description">
|
||||
<div class="form-floating mb-2">
|
||||
<input type="text" class="form-control" value="@CurrSashGroup.SelHardware.Description" readonly>
|
||||
<label>@Traduci("CWSash_Type")</label>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text">@Traduci("CWSash_Family")</label>
|
||||
<div class="form-floating mb-2">
|
||||
<select class="form-select" @bind="@FamilyHardware">
|
||||
@if (Sash.s_FamilyHardwareList == null || Sash.s_FamilyHardwareList.Count == 0)
|
||||
{
|
||||
@@ -124,20 +115,20 @@
|
||||
}
|
||||
}
|
||||
</select>
|
||||
<label>@Traduci("CWSash_Family")</label>
|
||||
</div>
|
||||
@if (string.IsNullOrEmpty(CurrSashGroup.SashShape))
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text">@Traduci("CWSash_Type")</label>
|
||||
<div class="form-floating mb-2">
|
||||
<select class="form-select">
|
||||
<option value="000000">Custom HW</option>
|
||||
</select>
|
||||
<label>@Traduci("CWSash_Type")</label>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text">@Traduci("CWSash_Type")</label>
|
||||
<div class="form-floating mb-2">
|
||||
<select class="form-select" @bind="SelHwType">
|
||||
<option value="000000">Custom HW</option>
|
||||
@foreach (var hlItem in CurrSashGroup.HardwareList)
|
||||
@@ -145,6 +136,7 @@
|
||||
<option value="@hlItem.Id">@hlItem.Description</option>
|
||||
}
|
||||
</select>
|
||||
<label>@Traduci("CWSash_Type")</label>
|
||||
</div>
|
||||
}
|
||||
|
||||
@@ -161,16 +153,14 @@
|
||||
|
||||
<div class="card shadow-sm rounded mb-4">
|
||||
<div class="card-body py-2">
|
||||
<div class="d-flex justify-content-end align-items-center">
|
||||
<div class="col-md-3">
|
||||
<select class="form-select" @bind="@MeasureType">
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="d-flex gap-2 ms-auto">
|
||||
<select class="form-select w-auto" @bind="@MeasureType">
|
||||
<option value="@MeasureTypes.ABSOLUTE">@Traduci("CWSash_Absolute") (mm)</option>
|
||||
<option value="@MeasureTypes.PROPORTIONAL">@Traduci("CWSash_Proportional") (*)</option>
|
||||
<option value="@MeasureTypes.PERCENTAGE">@Traduci("CWSash_Percentage") (%)</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<select class="form-select" @bind="@ChangeType">
|
||||
<select class="form-select w-auto" @bind="@ChangeType">
|
||||
<option value="0">@Traduci("CWSash_SashMeasure")</option>
|
||||
<option value="1">@Traduci("CWSash_GlassMeasure")</option>
|
||||
</select>
|
||||
|
||||
@@ -27,16 +27,14 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body py-2">
|
||||
<div class="d-flex justify-content-end align-items-center">
|
||||
<div class="col-md-3">
|
||||
<select class="form-select" @bind="@MeasureType">
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="d-flex gap-2 ms-auto">
|
||||
<select class="form-select w-auto" @bind="@MeasureType">
|
||||
<option value="@MeasureTypes.ABSOLUTE">@Traduci("CWSplit_Absolute") (mm)</option>
|
||||
<option value="@MeasureTypes.PROPORTIONAL">@Traduci("CWSplit_Proportional") (*)</option>
|
||||
<option value="@MeasureTypes.PERCENTAGE">@Traduci("CWSplit_Percentage") (%)</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<select class="form-select">
|
||||
<select class="form-select w-auto">
|
||||
<option value="1">@Traduci("CWSplit_Glass")</option>
|
||||
</select>
|
||||
</div>
|
||||
@@ -48,7 +46,7 @@
|
||||
</div>
|
||||
@if (BaseUser)
|
||||
{
|
||||
<div class="input-group mb-2">
|
||||
<div class="row align-items-center mb-2">
|
||||
@foreach (var i in CurrSplit.SplitShapeList)
|
||||
{
|
||||
<div class="col-auto">
|
||||
@@ -61,8 +59,8 @@
|
||||
@if (CurrSplit.SelSplitShape == Json.WindowConst.SplitShapes.GRID)
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto me-1" disabled="disabled" type="checkbox" name="SplitStartVert" checked="@CurrSplit.bSplitStartVert">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CwSplit_StartVert")</label>
|
||||
<input class="form-check-input ml-auto me-1" type="checkbox" checked="@CurrSplit.bSplitStartVert" @onclick:preventDefault>
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWSplit_StartVert")</label>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@@ -83,7 +81,7 @@
|
||||
@if (CurrSplit.SelSplitShape == Json.WindowConst.SplitShapes.GRID)
|
||||
{
|
||||
<div class="px-1">
|
||||
<input class="form-check-input ml-auto me-1" type="checkbox" name="SplitStartVert" checked="@CurrSplit.bSplitStartVert" @oninput="(ChangeEventArgs e) => ChangeStartVert(e)">
|
||||
<input class="form-check-input ml-auto me-1" type="checkbox" checked="@CurrSplit.bSplitStartVert" @oninput="(ChangeEventArgs e) => ChangeStartVert(e)">
|
||||
<label class="form-check-label fs-6 text-dark">@Traduci("CWSplit_StartVert")</label>
|
||||
</div>
|
||||
}
|
||||
@@ -92,9 +90,9 @@
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<hr />
|
||||
@if (CurrSplit.nSplitQtyHoriz > 0)
|
||||
{
|
||||
<hr />
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWSplit_HorizSplit")</h6>
|
||||
</div>
|
||||
@@ -133,12 +131,9 @@
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (CurrSplit.nSplitQtyVert > 0 && CurrSplit.nSplitQtyHoriz > 0)
|
||||
{
|
||||
<hr/>
|
||||
}
|
||||
@if (CurrSplit.nSplitQtyVert > 0)
|
||||
{
|
||||
<hr />
|
||||
<div class="row">
|
||||
<div class="d-flex justify-content-start align-items-center" style="min-height: 2.5rem;">
|
||||
<h6 class="fw-bold">@Traduci("CWSplit_VertSplit")</h6>
|
||||
|
||||
@@ -1,157 +1,175 @@
|
||||
@using static WebWindowComplex.LayoutConst
|
||||
|
||||
@* <div class="table-responsive"> *@
|
||||
<table class="table table-responsive table-sm mx-auto table-hover align-middle table-borderless">
|
||||
<colgroup>
|
||||
@for (int i = 0; i < maxCol; i++)
|
||||
{
|
||||
<col style="min-width: 80px;" />
|
||||
}
|
||||
</colgroup>
|
||||
<tbody>
|
||||
@for (int i = 0; i < ItemTableList.Count; i++)
|
||||
{
|
||||
<tr>
|
||||
@for (int j = 0; j < maxCol; j++)
|
||||
<table class="table table-responsive table-sm mx-auto table-hover align-middle table-borderless">
|
||||
<colgroup>
|
||||
@for (int i = 0; i < maxCol; i++)
|
||||
{
|
||||
<col style="min-width: 80px;" />
|
||||
}
|
||||
</colgroup>
|
||||
<tbody>
|
||||
@for (int i = 0; i < ItemTableList.Count; i++)
|
||||
{
|
||||
<tr>
|
||||
@for (int j = 0; j < maxCol; j++)
|
||||
{
|
||||
var index = RowCollapsedDict.Keys.Order().Where(k => k <= i).LastOrDefault();
|
||||
@if ((RowCollapsedDict.ContainsValue(true) && RowCollapsedDict.GetValueOrDefault(index))
|
||||
&& i - 1 > 0 && ItemTableList.ElementAt(i).Col > ItemTableList.ElementAt(index-1).Col){
|
||||
continue;
|
||||
}
|
||||
else
|
||||
{
|
||||
var index = RowCollapsedDict.Keys.Order().Where(k => k <= i).LastOrDefault();
|
||||
@if ((RowCollapsedDict.ContainsValue(true) && RowCollapsedDict.GetValueOrDefault(index))
|
||||
&& i - 1 > 0 && ItemTableList.ElementAt(i).Col > ItemTableList.ElementAt(index-1).Col){
|
||||
continue;
|
||||
}
|
||||
else
|
||||
CompileStep cs = CompileStep.Frame;
|
||||
int row = i;
|
||||
int ind = -1;
|
||||
string s = "Vai a step ";
|
||||
@if (j + 1 == ItemTableList[i].Col)
|
||||
{
|
||||
CompileStep cs = CompileStep.Frame;
|
||||
int row = i;
|
||||
int ind = -1;
|
||||
string s = "Vai a step ";
|
||||
@if (j + 1 == ItemTableList[i].Col)
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FRAME)
|
||||
{
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FRAME)
|
||||
{
|
||||
cs = CompileStep.Frame;
|
||||
s = s + cs.ToString();
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SPLIT)
|
||||
{
|
||||
cs = CompileStep.Split;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1): "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SASH)
|
||||
{
|
||||
cs = CompileStep.Sash;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FILL)
|
||||
{
|
||||
cs = CompileStep.Fill;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.INGLESINA)
|
||||
{
|
||||
cs = CompileStep.Inglesina;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
<td colspan="2">
|
||||
<div class="card text-center p-1 shadow-sm hover-shadow w-100">
|
||||
<div class="d-flex gap-2">
|
||||
<button class="btn btn-sm btn-rounded flex-grow-1" @onclick="() => RaiseNextStep(cs, ind)" title="@(s)"
|
||||
style="font-size: 1rem;flex-basis: 80%;">
|
||||
@ItemTableList[i].Desc
|
||||
cs = CompileStep.Frame;
|
||||
s = s + cs.ToString();
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SPLIT)
|
||||
{
|
||||
cs = CompileStep.Split;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1): "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SASH)
|
||||
{
|
||||
cs = CompileStep.Sash;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FILL)
|
||||
{
|
||||
cs = CompileStep.Fill;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
else if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.INGLESINA)
|
||||
{
|
||||
cs = CompileStep.Inglesina;
|
||||
ind = ItemTableList[i].IndexItem;
|
||||
s = s + cs.ToString() + ((ind + 1) > 0 ? (ind + 1) : "");
|
||||
}
|
||||
<td colspan="2">
|
||||
<div class="card text-center p-1 shadow-sm hover-shadow w-100">
|
||||
<div class="d-flex gap-2">
|
||||
<button class="btn btn-sm btn-rounded flex-grow-1" @onclick="() => RaiseNextStep(cs, ind)" title="@(s)"
|
||||
style="font-size: 1rem;flex-basis: 80%;">
|
||||
@ItemTableList[i].Desc
|
||||
</button>
|
||||
@* @if (ItemTableList[row].NumChild > 3)
|
||||
{
|
||||
<button class="btn btn-sm" @onclick="() => ChangeCollapsed(ItemTableList[row].Row)"
|
||||
style="bs-btn-padding-y: .25rem; bs-btn-padding-x: .5rem; bs-btn-font-size: .75rem; flex-basis: 20%;">
|
||||
<i class="@ChildIcon(ItemTableList[i].Row)" style="width:0.5rem;"></i>
|
||||
</button>
|
||||
@if (ItemTableList[row].NumChild > 3)
|
||||
} *@
|
||||
@if(!BaseUser)
|
||||
{
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SASH ||
|
||||
ItemTableList[i].Type is Json.WindowConst.AreaTypes.SPLIT ||
|
||||
ItemTableList[i].Type is Json.WindowConst.AreaTypes.INGLESINA)
|
||||
{
|
||||
<button class="btn btn-sm" @onclick="() => ChangeCollapsed(ItemTableList[row].Row)"
|
||||
style="bs-btn-padding-y: .25rem; bs-btn-padding-x: .5rem; bs-btn-font-size: .75rem; flex-basis: 20%;">
|
||||
<i class="@hwIcon(ItemTableList[i].Row)" style="width:0.5rem;"></i>
|
||||
<button class="btn btn-sm" style="font-size: 1rem; flex-basis: 20%;" @onclick="() => Remove(cs, ind)" title="@Traduci("CWTree_Remove")">
|
||||
<i class="fa-solid fa-trash"></i>
|
||||
</button>
|
||||
}
|
||||
@if(!BaseUser)
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FRAME &&
|
||||
((SashGroupList.Count == 0 && SplitList.Count == 0) || !(FrameWindow.AreaList.First() is Split)))
|
||||
{
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.SASH ||
|
||||
ItemTableList[i].Type is Json.WindowConst.AreaTypes.SPLIT ||
|
||||
ItemTableList[i].Type is Json.WindowConst.AreaTypes.INGLESINA)
|
||||
{
|
||||
<button class="btn btn-sm" style="font-size: 1rem; flex-basis: 20%;" @onclick="() => Remove(cs, ind)" title="@Traduci("CWTree_Remove")">
|
||||
<i class="fa-solid fa-trash"></i>
|
||||
<div class="dropdown px-4" @onfocusout="HandleFocusOutFrame">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="ToggleDropdownFrame">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
}
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FRAME &&
|
||||
((SashGroupList.Count == 0 && SplitList.Count == 0) || !(FrameWindow.AreaList.First() is Split)))
|
||||
<ul class="dropdown-menu @(isOpenFrame ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
@if (SashGroupList.Count == 0 && SplitList.Count == 0)
|
||||
{
|
||||
<li><button class="dropdown-item" @onclick="RaiseAddSash">@Traduci("CWTree_Sash")</button></li>
|
||||
}
|
||||
@if (!(FrameWindow.AreaList.First() is Split))
|
||||
{
|
||||
<li><button class="dropdown-item" @onclick="RaiseAddSplit">@Traduci("CWTree_Split")</button></li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FILL)
|
||||
{
|
||||
int currIndexFill = ItemTableList[i].IndexItem;
|
||||
if (FillList.ElementAt(currIndexFill).ParentArea is Frame)
|
||||
{
|
||||
<div class="dropdown px-4">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="ToggleDropdownFrame">
|
||||
<div class="dropdown px-4" @onfocusout="() => HandleFocusOutFill(currIndexFill)">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="() => ToggleDropdownFill(currIndexFill)">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpenFrame ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
@if (SashGroupList.Count == 0 && SplitList.Count == 0)
|
||||
{
|
||||
<li><button class="dropdown-item" @onclick="RaiseAddSash">@Traduci("CWTree_Sash")</button></li>
|
||||
}
|
||||
@if (!(FrameWindow.AreaList.First() is Split))
|
||||
{
|
||||
<li><button class="dropdown-item" @onclick="RaiseAddSplit">@Traduci("CWTree_Split")</button></li>
|
||||
}
|
||||
<ul class="dropdown-menu @(isOpenFill.ElementAt(currIndexFill) ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
<li><button class="dropdown-item" @onclick="() => AddInglesinaIntoFill(currIndexFill)">@Traduci("CWTree_AddInglesina")</button></li>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
@if (ItemTableList[i].Type is Json.WindowConst.AreaTypes.FILL)
|
||||
else if (SplittedList != null && SplittedList.Count > 0)
|
||||
{
|
||||
int currIndexFill = ItemTableList[i].IndexItem;
|
||||
if (FillList.ElementAt(currIndexFill).ParentArea is Frame)
|
||||
Splitted? currSplitted = SplittedList.Where(x => x.AreaList.First().Equals(FillList[currIndexFill])).FirstOrDefault();
|
||||
@if (currSplitted != null)
|
||||
{
|
||||
<div class="dropdown px-4">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="() => ToggleDropdownFill(currIndexFill)">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpenFill.ElementAt(currIndexFill) ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
<li><button class="dropdown-item" @onclick="() => AddInglesinaIntoFill(currIndexFill)">@Traduci("CWTree_AddInglesina")</button></li>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
else if (SplittedList != null && SplittedList.Count > 0)
|
||||
{
|
||||
Splitted? currSplitted = SplittedList.Where(x => x.AreaList.First().Equals(FillList[currIndexFill])).FirstOrDefault();
|
||||
@if (currSplitted != null)
|
||||
@if (currSplitted.ParentArea != null && currSplitted.ParentWindow != null
|
||||
&& currSplitted.AreaList.FirstOrDefault() != null && currSplitted.AreaList.First()!.AreaList.Count == 0)
|
||||
{
|
||||
@if (currSplitted.ParentArea != null && currSplitted.ParentWindow != null
|
||||
&& currSplitted.AreaList.FirstOrDefault() != null && currSplitted.AreaList.First()!.AreaList.Count == 0)
|
||||
{
|
||||
<div class="dropdown px-4">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="() => ToggleDropdownFill(currIndexFill)">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpenFill.ElementAt(currIndexFill) ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
<li><button class="dropdown-item" @onclick="() => AddInglesinaIntoFill(currIndexFill)">@Traduci("CWTree_AddInglesina")</button></li>
|
||||
<div class="dropdown px-4" @onfocusout="() => HandleFocusOutFill(currIndexFill)">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="() => ToggleDropdownFill(currIndexFill)">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpenFill.ElementAt(currIndexFill) ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
<li><button class="dropdown-item" @onclick="() => AddSashIntoFill(currIndexFill)">@Traduci("CWTree_AddSash")</button></li>
|
||||
@for (int k = 0; k < SashGroupList.Count; k++)
|
||||
{
|
||||
int Index = k;
|
||||
@for (int k = 0; k < SashGroupList.Count; k++)
|
||||
{
|
||||
int Index = k;
|
||||
<li><button class="dropdown-item" @onclick="() => CopySashIntoFill(Index, currIndexFill)">@Traduci("CWTree_CopySash") @(SashGroupList.Count == 1 ? "" : (Index + 1))</button></li>
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (FillList.ElementAt(currIndexFill).ParentArea is Splitted && FillList.ElementAt(currIndexFill).ParentArea.ParentArea is Sash)
|
||||
{
|
||||
<div class="dropdown px-4" @onfocusout="() => HandleFocusOutFill(currIndexFill)">
|
||||
<button class="btn btn-sm dropdown-toggle" type="button" @onclick="() => ToggleDropdownFill(currIndexFill)">
|
||||
<i class="fa-solid fa-plus"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu @(isOpenFill.ElementAt(currIndexFill) ? "show" : "")" style="min-width:5rem; max-width:10rem">
|
||||
<li><button class="dropdown-item" @onclick="() => AddInglesinaIntoFill(currIndexFill)">@Traduci("CWTree_AddInglesina")</button></li>
|
||||
</ul>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</td>
|
||||
}
|
||||
else
|
||||
{
|
||||
<td> </td>
|
||||
}
|
||||
</div>
|
||||
</td>
|
||||
<td class="text-start" colspan="1">
|
||||
@if (ItemTableList[row].NumChild > 3)
|
||||
{
|
||||
<div class="card text-center p-0 shadow-sm hover-shadow w-25">
|
||||
<button class="btn btn-sm" @onclick="() => ChangeCollapsed(ItemTableList[row].Row)">
|
||||
<i class="@ChildIcon(ItemTableList[i].Row)" style="width:0.5rem;"></i>
|
||||
</button>
|
||||
</div>
|
||||
}
|
||||
</td>
|
||||
}
|
||||
else
|
||||
{
|
||||
<td> </td>
|
||||
}
|
||||
}
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
@* </div> *@
|
||||
}
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -6,6 +6,8 @@ namespace WebWindowComplex.Compo
|
||||
{
|
||||
public partial class CardTree
|
||||
{
|
||||
#region Public Properties
|
||||
|
||||
/// <summary>
|
||||
/// Lista oggetti ItemTable
|
||||
/// </summary>
|
||||
@@ -126,14 +128,18 @@ namespace WebWindowComplex.Compo
|
||||
[Parameter]
|
||||
public EventCallback<List<string>> EC_ReqTraduzione { get; set; }
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
//if (Vocabulary == null || Vocabulary.Count != 6)
|
||||
//{
|
||||
// List<string> tradList = new List<string>() { "CWTree_Remove", "CWTree_Sash", "CWTree_Split", "CWTree_AddInglesina", "CWTree_AddSash", "CWTree_CopySash" };
|
||||
// await EC_ReqTraduzione.InvokeAsync(tradList);
|
||||
//}
|
||||
}
|
||||
#endregion Public Properties
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
//protected override async Task OnInitializedAsync()
|
||||
//{
|
||||
// if (Vocabulary == null || Vocabulary.Count != 6)
|
||||
// {
|
||||
// List<string> tradList = new List<string>() { "CWTree_Remove", "CWTree_Sash", "CWTree_Split", "CWTree_AddInglesina", "CWTree_AddSash", "CWTree_CopySash" };
|
||||
// await EC_ReqTraduzione.InvokeAsync(tradList);
|
||||
// }
|
||||
//}
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
@@ -143,6 +149,18 @@ namespace WebWindowComplex.Compo
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private bool isOpenFrame = false;
|
||||
|
||||
private List<bool> isOpenFill = new();
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Methods
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per richiesta prossimo step
|
||||
/// </summary>
|
||||
@@ -167,7 +185,12 @@ namespace WebWindowComplex.Compo
|
||||
return EC_Collapsed.InvokeAsync(RowCollapsedDict);
|
||||
}
|
||||
|
||||
private string hwIcon(int row)
|
||||
/// <summary>
|
||||
/// Metodo per icona se sono presenti più di 3 figli
|
||||
/// </summary>
|
||||
/// <param name="row"></param>
|
||||
/// <returns></returns>
|
||||
private string ChildIcon(int row)
|
||||
{
|
||||
return RowCollapsedDict[row] ? "fa-solid fa-chevron-down" : "fa-solid fa-chevron-up";
|
||||
}
|
||||
@@ -215,7 +238,7 @@ namespace WebWindowComplex.Compo
|
||||
{
|
||||
FrameWindow.AddSplit();
|
||||
Split s = (Split)FrameWindow.AreaList[0];
|
||||
foreach(var item in s.AreaList)
|
||||
foreach (var item in s.AreaList)
|
||||
{
|
||||
if (item.AreaList.FirstOrDefault() is Fill)
|
||||
isOpenFill.Add(false);
|
||||
@@ -261,7 +284,7 @@ namespace WebWindowComplex.Compo
|
||||
currSplitted.AddInglesina();
|
||||
return EC_UpdateSplitted.InvokeAsync(currSplitted);
|
||||
}
|
||||
else if(FillList.ElementAt(currIndexFill).ParentArea is Frame)
|
||||
else if (FillList.ElementAt(currIndexFill).ParentArea is Frame)
|
||||
{
|
||||
currFrame = (Frame)FillList.ElementAt(currIndexFill).ParentArea;
|
||||
currFrame.AddInglesina();
|
||||
@@ -293,20 +316,45 @@ namespace WebWindowComplex.Compo
|
||||
return EC_UpdateSplitted.InvokeAsync(currSplitted);
|
||||
}
|
||||
|
||||
private bool isOpenFrame = false;
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per aprire/chiudere dropdown
|
||||
/// </summary>
|
||||
private void ToggleDropdownFrame()
|
||||
{
|
||||
isOpenFrame = !isOpenFrame;
|
||||
}
|
||||
|
||||
private List<bool> isOpenFill = new();
|
||||
/// <summary>
|
||||
/// Chiude dropdown quando l'utente clicca all'esterno
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private async Task HandleFocusOutFrame()
|
||||
{
|
||||
// Un piccolo delay assicura che l'evento @onclick dell'item venga eseguito prima di chiudere il menu
|
||||
await Task.Delay(150);
|
||||
isOpenFrame = false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per aprire/chiudere dropdown
|
||||
/// </summary>
|
||||
/// <param name="currIndexFill"></param>
|
||||
private void ToggleDropdownFill(int currIndexFill)
|
||||
{
|
||||
isOpenFill[currIndexFill] = !isOpenFill.ElementAt(currIndexFill);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Chiude dropdown quando l'utente clicca all'esterno
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private async Task HandleFocusOutFill(int currIndexFill)
|
||||
{
|
||||
// Un piccolo delay assicura che l'evento @onclick dell'item venga eseguito prima di chiudere il menu
|
||||
await Task.Delay(150);
|
||||
isOpenFill[currIndexFill] = false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Metodo per traduzione in lingua corrente
|
||||
/// </summary>
|
||||
@@ -322,6 +370,8 @@ namespace WebWindowComplex.Compo
|
||||
return ans;
|
||||
}
|
||||
|
||||
#endregion Private Methods
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
@using static WebWindowComplex.LayoutConst
|
||||
<div class="input-group mb-2">
|
||||
@* <span class="input-group-text">@(name())</span> *@
|
||||
<label class="input-group-text px-2 py-1">
|
||||
<img class="img-fluid" src="@GetImageElementPath(name())" title="@Traduci("CWElem_"+name())" width="52" />
|
||||
</label>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
@using static WebWindowComplex.LayoutConst
|
||||
|
||||
<div class="input-group mb-2">
|
||||
<label class="input-group-text px-2 py-1">
|
||||
<img class="img-fluid" src="@GetImageJointPosPath(CurrPosJointName)" title="@(CurrPosJointName)" width="50" />
|
||||
|
||||
@@ -28,7 +28,6 @@ namespace WebWindowComplex.Compo
|
||||
|
||||
#endregion Public Properties
|
||||
|
||||
private bool isOpen = false;
|
||||
private bool isOpenDropdown = false;
|
||||
|
||||
#region Private Properties
|
||||
@@ -67,7 +66,7 @@ namespace WebWindowComplex.Compo
|
||||
{
|
||||
// Un piccolo delay assicura che l'evento @onclick dell'item venga eseguito prima di chiudere il menu
|
||||
await Task.Delay(150);
|
||||
isOpen = false;
|
||||
isOpenDropdown = false;
|
||||
}
|
||||
|
||||
private void ToggleDropdownOpening()
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
<div class="input-group mb-2">
|
||||
<div class="form-floating mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<span class="input-group-text">@(CurrOpt.sName)</span>
|
||||
@if (CurrValue is String)
|
||||
{
|
||||
<input type="text" readonly class="form-control" value="@CurrOpt.ValueList.FirstOrDefault(x => x.sValue.Equals(CurrValue))!.sDescription">
|
||||
@@ -10,15 +9,16 @@
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@CurrOpt.ValueList.FirstOrDefault(x => x.sValue == CurrValue)!.sDescription">
|
||||
}
|
||||
<label>@(CurrOpt.sName)</label>
|
||||
}
|
||||
else
|
||||
{
|
||||
<label class="input-group-text">@(CurrOpt.sName)</label>
|
||||
<select class="form-select" @bind="CurrValue">
|
||||
@foreach (var currValueCombo in CurrOpt.ValueList)
|
||||
{
|
||||
<option value="@currValueCombo.sValue">@currValueCombo.sDescription</option>
|
||||
}
|
||||
</select>
|
||||
<label>@(CurrOpt.sName)</label>
|
||||
}
|
||||
</div>
|
||||
@@ -1,56 +1,48 @@
|
||||
<div class="input-group mb-2">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<span class="input-group-text">@(CurrOpt.sName)</span>
|
||||
@if (CurrOpt.sName.Equals("HMan"))
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@CurrValue">
|
||||
}
|
||||
else if (CurrOpt.ValueList.Count > 0)
|
||||
{
|
||||
if (CurrValue is String)
|
||||
<div class="form-floating">
|
||||
@if (CurrOpt.sName.Equals("HMan"))
|
||||
{
|
||||
<input type="text" readonly class="form-control" value="@CurrValue">
|
||||
<input type="number" class="form-control" value="@CurrValue" readonly>
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@CurrValue">
|
||||
if (CurrValue is String)
|
||||
{
|
||||
<input type="text" class="form-control" value="@CurrValue" readonly>
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" class="form-control" value="@CurrValue" readonly>
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (CurrValue is String)
|
||||
{
|
||||
<input type="text" readonly class="form-control" value="@CurrValue">
|
||||
}
|
||||
else
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@CurrValue">
|
||||
}
|
||||
}
|
||||
<label>@(CurrOpt.sName)</label>
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<label class="input-group-text">@(CurrOpt.sName)</label>
|
||||
@if (CurrOpt.sName.Equals("HMan"))
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@CurrValue">
|
||||
}
|
||||
else if (CurrOpt.ValueList.Count > 0)
|
||||
{
|
||||
<select class="form-select" @bind="CurrValue">
|
||||
@foreach (var currValueCombo in CurrOpt.ValueList)
|
||||
{
|
||||
<option value="@currValueCombo">@currValueCombo</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
else
|
||||
{
|
||||
<select class="form-select" @bind="CurrValue">
|
||||
<option value="@CurrOpt.sValue">@CurrOpt.sValue</option>
|
||||
</select>
|
||||
}
|
||||
|
||||
<div class="form-floating">
|
||||
@if (CurrOpt.sName.Equals("HMan"))
|
||||
{
|
||||
<input type="number" class="form-control" @bind="@CurrValue">
|
||||
}
|
||||
else if (CurrOpt.ValueList.Count > 0)
|
||||
{
|
||||
<select class="form-select" @bind="CurrValue">
|
||||
@foreach (var currValueCombo in CurrOpt.ValueList)
|
||||
{
|
||||
<option value="@currValueCombo">@currValueCombo</option>
|
||||
}
|
||||
</select>
|
||||
}
|
||||
else
|
||||
{
|
||||
<select class="form-select" @bind="CurrValue">
|
||||
<option value="@CurrOpt.sValue">@CurrOpt.sValue</option>
|
||||
</select>
|
||||
}
|
||||
<label>@(CurrOpt.sName)</label>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@@ -10,24 +10,15 @@
|
||||
@if(BaseUser)
|
||||
{
|
||||
<input type="number" readonly class="form-control" value="@CurrVal">
|
||||
@switch (CurrRec.SelMeasureType.ToString())
|
||||
{
|
||||
case "ABSOLUTE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">mm</span>
|
||||
break;
|
||||
}
|
||||
case "PROPORTIONAL":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">*</span>
|
||||
break;
|
||||
}
|
||||
case "PERCENTAGE":
|
||||
{
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
<span class="input-group-text" style="width:6rem; background-color:#e9ecef">
|
||||
@(CurrRec.SelMeasureType.ToString() switch
|
||||
{
|
||||
"Absolute" => "mm",
|
||||
"Proportional" => "*",
|
||||
"Percentage" => "%",
|
||||
_ => CurrRec.SelMeasureType.ToString()
|
||||
})
|
||||
</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -36,24 +27,13 @@
|
||||
@foreach (var mType in CurrRec.MeasureTypeList)
|
||||
{
|
||||
<option value=@(mType.Id)>
|
||||
@switch (mType.Name)
|
||||
@(mType.Name switch
|
||||
{
|
||||
case "Absolute":
|
||||
{
|
||||
<span class="input-group-text">mm</span>
|
||||
break;
|
||||
}
|
||||
case "Proportional":
|
||||
{
|
||||
<span class="input-group-text">*</span>
|
||||
break;
|
||||
}
|
||||
case "Percentage":
|
||||
{
|
||||
<span class="input-group-text">%</span>
|
||||
break;
|
||||
}
|
||||
}
|
||||
"Absolute" => "mm",
|
||||
"Proportional" => "*",
|
||||
"Percentage" => "%",
|
||||
_ => mType.Name
|
||||
})
|
||||
</option>
|
||||
}
|
||||
</select>
|
||||
|
||||
@@ -63,6 +63,7 @@
|
||||
"CWAreaS_AddInglesina",
|
||||
"CWAreaS_Element",
|
||||
"CWAreaS_Joints",
|
||||
"CWAreaS_Add",
|
||||
"CWSplit_Sash",
|
||||
"CWSplit_SashGroup",
|
||||
"CWSplit_Split",
|
||||
@@ -96,5 +97,26 @@
|
||||
"CWAreaSp_AddSash",
|
||||
"CWAreaSp_CopySash",
|
||||
"CWAreaSp_AddInglesina",
|
||||
"CWAreaSp_Sash"
|
||||
"CWAreaSp_Sash",
|
||||
"CWIng_Sash",
|
||||
"CWIng_SashGroup",
|
||||
"CWIng_Glass",
|
||||
"CWIng_Inglesina",
|
||||
"CWIng_RemoveIng",
|
||||
"CWIng_Shape",
|
||||
"CWIng_Horizontal",
|
||||
"CWIng_Vertical",
|
||||
"CWIng_Grid",
|
||||
"CWIng_Custom",
|
||||
"CWIng_StartVert",
|
||||
"CWIng_Side",
|
||||
"CWIng_Internal",
|
||||
"CWIng_External",
|
||||
"CWIng_Both",
|
||||
"CWIng_HorizIng",
|
||||
"CWIng_VerticalIng",
|
||||
"CWIng_QtyElem",
|
||||
"CWIng_Absolute",
|
||||
"CWIng_Proportional",
|
||||
"CWIng_Percentage"
|
||||
]
|
||||
@@ -101,7 +101,7 @@
|
||||
</div>
|
||||
<div class="card-body bg-transparent">
|
||||
<div class="row justify-content-between align-middle flex-wrap">
|
||||
<div class="col-md-6 col-lg-6">
|
||||
<div class="col-md-8 col-lg-6">
|
||||
@if (currStep == CompileStep.Tree)
|
||||
{
|
||||
<CardTree ItemTableList="m_ItemTableList"
|
||||
@@ -214,17 +214,19 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
<CascadingValue Value="BaseUser" Name="User">
|
||||
<CardInglesina CurrInglesina="InglesinaList[currInglesinaIndex]"
|
||||
SashGroupList="SashGroupList"
|
||||
InglesinaList="InglesinaList"
|
||||
FrameWindow="FrameWindow"
|
||||
EC_UpdateFrame="UpdatePreviewFrame"
|
||||
EC_ReqResetDict="ReqResetDict"
|
||||
EC_UpdateInglesina="UpdatePreviewInglesina"
|
||||
EC_ReqElement="UpdateElementSplit"
|
||||
EC_ReqClose="ReturnTree">
|
||||
</CardInglesina>
|
||||
<CascadingValue Value="CurrVocabulary" Name="Vocabulary">
|
||||
<CascadingValue Value="BaseUser" Name="User">
|
||||
<CardInglesina CurrInglesina="InglesinaList[currInglesinaIndex]"
|
||||
SashGroupList="SashGroupList"
|
||||
InglesinaList="InglesinaList"
|
||||
FrameWindow="FrameWindow"
|
||||
EC_UpdateFrame="UpdatePreviewFrame"
|
||||
EC_ReqResetDict="ReqResetDict"
|
||||
EC_UpdateInglesina="UpdatePreviewInglesina"
|
||||
EC_ReqElement="UpdateElementSplit"
|
||||
EC_ReqClose="ReturnTree">
|
||||
</CardInglesina>
|
||||
</CascadingValue>
|
||||
</CascadingValue>
|
||||
}
|
||||
}
|
||||
@@ -253,21 +255,21 @@
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="@buttonFillCss(Json.WindowConst.FillTypes.GLASS)">@Traduci("CWTableC_AllGlass")</button>
|
||||
<button class="btn-icone @buttonFillCss(Json.WindowConst.FillTypes.GLASS)">@Traduci("CWTableC_AllGlass")</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="@buttonFillCss(Json.WindowConst.FillTypes.GLASS)" @onclick="() => ChangeAllFill(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWTableC_AllGlass")</button>
|
||||
<button class="btn-icone @buttonFillCss(Json.WindowConst.FillTypes.GLASS)" @onclick="() => ChangeAllFill(WebWindowComplex.Json.WindowConst.FillTypes.GLASS)">@Traduci("CWTableC_AllGlass")</button>
|
||||
}
|
||||
</div>
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
@if (BaseUser)
|
||||
{
|
||||
<button class="@buttonFillCss(Json.WindowConst.FillTypes.WOOD)">@Traduci("CWTableC_AllWood")</button>
|
||||
<button class="btn-icone @buttonFillCss(Json.WindowConst.FillTypes.WOOD)">@Traduci("CWTableC_AllWood")</button>
|
||||
}
|
||||
else
|
||||
{
|
||||
<button class="@buttonFillCss(Json.WindowConst.FillTypes.WOOD)" @onclick="() => ChangeAllFill(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWTableC_AllWood")</button>
|
||||
<button class="btn-icone @buttonFillCss(Json.WindowConst.FillTypes.WOOD)" @onclick="() => ChangeAllFill(WebWindowComplex.Json.WindowConst.FillTypes.WOOD)">@Traduci("CWTableC_AllWood")</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
@@ -309,7 +311,7 @@
|
||||
</CardArcElement>
|
||||
} *@
|
||||
</div>
|
||||
<div class="col-md-6 col-lg-6">
|
||||
<div class="col-md-4 col-lg-6">
|
||||
@if (string.IsNullOrWhiteSpace(LiveData.SvgPreview))
|
||||
{
|
||||
<LoadingData DisplayMode="LoadingData.SpinMode.Normal" DisplaySize="LoadingData.CtrlSize.Large"></LoadingData>
|
||||
@@ -343,24 +345,6 @@
|
||||
</div>
|
||||
}
|
||||
}
|
||||
@* <ul class="list-group">
|
||||
@if (PendReq != null && PendReq.Count > 0)
|
||||
{
|
||||
foreach (var item in PendReq)
|
||||
{
|
||||
<li class="list-group-item">
|
||||
<div class="d-flex flex-column gap-2 flex-wrap">
|
||||
<div class="input-group mb-2 justify-content-center">
|
||||
<label class="input-group-text">@item.Key</label>
|
||||
<input type="text" readonly class="form-control" value="@(item.Value)">
|
||||
<button class="btn btn-sm btn-warning" title="Non cambiare" @onclick="() => DoChangePend(item.Key,false)"><i class="fa-solid fa-ban"></i></button>
|
||||
<button class="btn btn-sm btn-success" title="Cambia" @onclick="() => DoChangePend(item.Key,true)"><i class="fa-solid fa-check"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
}
|
||||
}
|
||||
</ul> *@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -629,9 +629,9 @@ namespace WebWindowComplex
|
||||
foreach (var fill in FillList)
|
||||
{
|
||||
if (!fill.FillType.Equals(reqFillTypes))
|
||||
return "btn btn-outline-secondary btn-sm";
|
||||
return "";
|
||||
}
|
||||
return "btn btn-secondary btn-sm";
|
||||
return "active";
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -967,7 +967,7 @@ namespace WebWindowComplex
|
||||
}
|
||||
case AreaTypes.SPLITTED:
|
||||
{
|
||||
if (node.ParentArea is Split && !IntoSash)
|
||||
if (node.ParentArea is Split)
|
||||
{
|
||||
m_SplittedList.Add((Splitted)node);
|
||||
}
|
||||
|
||||
@@ -35,3 +35,45 @@ hr {
|
||||
border: 0;
|
||||
border-top: 1px solid rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
/* Stato Normale (Non Attivo) */
|
||||
.btn-icone {
|
||||
background-color: #ffffff;
|
||||
border: 2px solid #d1d5db; /* Bordo grigio tenue di media visibilità */
|
||||
box-shadow: 0 4px 12px rgba(212, 230, 250, 0.8); /* Ombra azzurra delicata */
|
||||
font-weight: 400;
|
||||
padding: 10px 22px;
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
transition: transform 0.2s ease, background-color 0.2s ease, border 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
|
||||
}
|
||||
|
||||
/* Hover (Passaggio del mouse - si applica in tutti gli stati) */
|
||||
.btn-icone:hover {
|
||||
transform: scale(1.08); /* Ingrandimento del bottone */
|
||||
border-color: #9ca3af; /* Bordo grigio leggermente più nitido all'hover */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35); /* Ombra blu leggermente più intensa */
|
||||
}
|
||||
|
||||
/* Stato Attivo (Selezionato) */
|
||||
.btn-icone.active {
|
||||
background-color: #ffffff; /* Sfondo bianco */
|
||||
border: 3px solid #a6ccf5; /* Bordo azzurro */
|
||||
box-shadow: 0 2px 8px rgba(2, 132, 199, 0.2);
|
||||
}
|
||||
|
||||
/* Hover specifico quando il bottone è Attivo */
|
||||
.btn-icone.active:hover {
|
||||
transform: scale(1.08);
|
||||
background-color: #ffffff; /* Azzurro leggermente più carico al passaggio */
|
||||
border-color: #a6ccf5; /* Sottile affinamento del bordo */
|
||||
box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35);
|
||||
}
|
||||
|
||||
/* Effetto Pressione al Click (Mouse premuto) */
|
||||
.btn-icone:active,
|
||||
.btn-icone.active:active {
|
||||
transform: scale(0.96) translateY(2px);
|
||||
box-shadow: 0 2px 4px rgba(212, 230, 250, 0.15);
|
||||
transition: transform 0.05s ease, box-shadow 0.05s ease;
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Version>3.1.8.2016</Version>
|
||||
<Version>3.1.8.2614</Version>
|
||||
<Authors>Annamaria Sassi</Authors>
|
||||
<Company>Egalware</Company>
|
||||
<Description>Componente gestione Configurazioni avanzate Window per LUX</Description>
|
||||
@@ -58,6 +58,14 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Version>3.1.8.2016</Version>
|
||||
<Version>3.1.8.2614</Version>
|
||||
<Authors>Annamaria Sassi</Authors>
|
||||
<Company>Egalware</Company>
|
||||
<Description>Componente gestione JWD per LUX</Description>
|
||||
@@ -68,6 +68,78 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user