clean up device editor
This commit is contained in:
parent
629d484160
commit
376e8927e7
3 changed files with 25 additions and 17 deletions
|
|
@ -1720,34 +1720,34 @@ gapp.register("kiri.init", [], (root, exports) => {
|
|||
|
||||
devbed: newRow([
|
||||
uc.newLabel(LANG.volume, { class: "grow" }),
|
||||
uc.newLabel('X'),
|
||||
uc.newLabel('X', { class: "dim" }),
|
||||
ui.bedWidth = newInput2({title:LANG.dv_bedw_l, convert:toFloat, size:5, units:true, round:2, action:updateDeviceSize}),
|
||||
uc.newLabel('Y'),
|
||||
uc.newLabel('Y', { class: "dim" }),
|
||||
ui.bedDepth = newInput2({title:LANG.dv_bedd_l, convert:toFloat, size:5, units:true, round:2, action:updateDeviceSize}),
|
||||
uc.newLabel('Z'),
|
||||
uc.newLabel('Z', { class: "dim" }),
|
||||
ui.maxHeight = newInput2({title:LANG.dv_bedh_l, convert:toFloat, size:5, modes:FDM_SLA, action:updateDeviceSize}),
|
||||
], { class: "var-area" }),
|
||||
], { class: "var-row" }),
|
||||
|
||||
resolutionX: newInput(LANG.dv_rezx_s, {title:LANG.dv_rezx_l, convert:toInt, size:5, modes:SLA}),
|
||||
resolutionY: newInput(LANG.dv_rezy_s, {title:LANG.dv_rezy_l, convert:toInt, size:5, modes:SLA}),
|
||||
spindleMax: newInput(LANG.dv_spmx_s, {title:LANG.dv_spmx_l, convert:toInt, size:5, modes:CAM, trigger:1}),
|
||||
deviceZMax: newInput(LANG.dv_zmax_s, {title:LANG.dv_zmax_l, convert:toInt, size:5, modes:FDM}),
|
||||
gcodeTime: newInput(LANG.dv_time_s, {title:LANG.dv_time_l, convert:toFloat, size:5, modes:FDM}),
|
||||
separator: newBlank({class:"pop-sep", modes:FDM}),
|
||||
separator: newBlank({class:"pop-sep", modes:FDM, driven:true}),
|
||||
filamentSource: newSelect(LANG.dv_fsrc_s, {title: LANG.dv_fsrc_l, action: filamentSourceSave, modes:FDM}, "filasrc"),
|
||||
fwRetract: newBoolean(LANG.dv_retr_s, onBooleanClick, {title:LANG.dv_retr_l, modes:FDM}),
|
||||
deviceOrigin: newBoolean(LANG.dv_orgc_s, onBooleanClick, {title:LANG.dv_orgc_l, modes:FDM_LZR, show:() => !ui.deviceRound.checked}),
|
||||
deviceRound: newBoolean(LANG.dv_bedc_s, onBooleanClick, {title:LANG.dv_bedc_l, trigger:true, show:isNotBelt}),
|
||||
deviceBelt: newBoolean(LANG.dv_belt_s, onBooleanClick, {title:LANG.dv_belt_l, trigger:true, show:() => !ui.deviceRound.checked}),
|
||||
_____: newGroup(LANG.dv_gr_ext, $('device2'), {group:"dext", inline:true, modes:FDM}),
|
||||
extruder: newGroup(LANG.dv_gr_ext, $('device2'), {group:"dext", inline:true, modes:FDM}),
|
||||
extFilament: newInput(LANG.dv_fila_s, {title:LANG.dv_fila_l, convert:toFloat, modes:FDM}),
|
||||
extNozzle: newInput(LANG.dv_nozl_s, {title:LANG.dv_nozl_l, convert:toFloat, modes:FDM}),
|
||||
extOffsetX: newInput(LANG.dv_exox_s, {title:LANG.dv_exox_l, convert:toFloat, modes:FDM}),
|
||||
extOffsetY: newInput(LANG.dv_exoy_s, {title:LANG.dv_exoy_l, convert:toFloat, modes:FDM}),
|
||||
extruder: newGroup(LANG.dv_gr_ext, $('device2'), {group:"dext", inline:true, modes:FDM}),
|
||||
separator: newBlank({class:"set-sep", modes:FDM, driven:true}),
|
||||
_____: newGroup(LANG.dv_gr_too, $('device2'), {group:"dext", inline:true, modes:CAM_LZR}),
|
||||
extSelect: newText(LANG.dv_exts_s, {title:LANG.dv_exts_l, size:14, height:3, area:gcode}),
|
||||
extDeselect: newText(LANG.dv_dext_s, {title:LANG.dv_dext_l, size:14, height:3, area:gcode}),
|
||||
extSelect: newText(LANG.dv_exts_s, {title:LANG.dv_exts_l, size:14, height:3, area:gcode, modes:GCODE}),
|
||||
extDeselect: newText(LANG.dv_dext_s, {title:LANG.dv_dext_l, size:14, height:3, area:gcode, modes:GCODE}),
|
||||
extPad: newBlank({class:"grow", modes:FDM}),
|
||||
extActions: newRow([
|
||||
ui.extPrev = newButton(undefined, undefined, {icon:'<i class="fas fa-less-than"></i>'}),
|
||||
|
|
|
|||
|
|
@ -908,6 +908,8 @@ gapp.register("kiri.main", [], (root, exports) => {
|
|||
options.selectedIndex = optlist.indexOf(mode);
|
||||
modename.onchange = (ev) => setMode(optlist[options.selectedIndex]);
|
||||
}
|
||||
// gcode edit area for any non-SLA mode
|
||||
api.uc.setVisible($('gcode-edit'), mode !== 'SLA');
|
||||
// highlight selected mode menu item
|
||||
["FDM","CAM","SLA","LASER"].forEach(sm => {
|
||||
const cl = $(`mode-${sm.toLowerCase()}`).classList;
|
||||
|
|
|
|||
|
|
@ -439,6 +439,9 @@ th, tr, td, label {
|
|||
.grow {
|
||||
flex-grow: 1;
|
||||
}
|
||||
.shrink0 {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
.a-start {
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
|
@ -1229,7 +1232,6 @@ th, tr, td, label {
|
|||
display: none;
|
||||
padding: 10px;
|
||||
min-height: 20px;
|
||||
font-size: smaller;
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
|
|
@ -1243,10 +1245,16 @@ th, tr, td, label {
|
|||
max-height: 350px;
|
||||
}
|
||||
#mod-x {
|
||||
border-radius: 5px;
|
||||
border: 2px solid rgba(255,255,255,0.5);
|
||||
background-color: rgba(255,255,255,0.5);
|
||||
position: absolute;
|
||||
z-index: 30;
|
||||
bottom: -20px;
|
||||
right: 5px;
|
||||
right: 0;
|
||||
}
|
||||
#mod-x svg {
|
||||
aspect-ratio: 1 / 1 !important;
|
||||
}
|
||||
#mod-setup {
|
||||
height: 550px;
|
||||
|
|
@ -2048,14 +2056,12 @@ th, tr, td, label {
|
|||
flex-grow: 1;
|
||||
font-size: smaller;
|
||||
}
|
||||
.var-area {
|
||||
gap: 3px;
|
||||
}
|
||||
.var-area label {
|
||||
padding: 2px 0 2px 0;
|
||||
.var-row .dim {
|
||||
text-align: right;
|
||||
padding-right: 3px;
|
||||
font-size: smaller;
|
||||
}
|
||||
.var-row input, .var-area input {
|
||||
.var-row input {
|
||||
margin-right: 0;
|
||||
margin-bottom: 1px;
|
||||
padding-bottom: 1px;
|
||||
|
|
|
|||
Loading…
Reference in a new issue