fix(project): restore smooth quarter toggles
Hide monthly content until column widths settle to prevent numeric shifts during expansion.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}
|
||||
<link rel="stylesheet" href="/static/project.css?v=20261003m" />
|
||||
<link rel="stylesheet" href="/static/project.css?v=20261003n" />
|
||||
<link rel="stylesheet" href="/static/vendor/material-symbols/material-symbols.css" />
|
||||
{% endblock %}
|
||||
|
||||
@@ -202,5 +202,5 @@
|
||||
{% include "project/_member_tasks_modal.html" %}
|
||||
|
||||
<script src="/static/project-goal-text.js?v=20261003d" defer></script>
|
||||
<script src="/static/project.js?v=20261003m" defer></script>
|
||||
<script src="/static/project.js?v=20261003n" defer></script>
|
||||
{% endblock %}
|
||||
|
||||
@@ -543,7 +543,7 @@
|
||||
|
||||
<h3 id="goals-table">분기 접기·열 너비·행 높이</h3>
|
||||
<ul>
|
||||
<li>열은 연간 → 1~3월 → 1분기 → 4~6월 → 2분기 → 7~9월 → 3분기 → 10~12월 → 4분기 순서입니다. <b>분기 머리 칸</b>을 누르면 해당 월 3개가 즉시 접히거나 원래 너비로 펼쳐집니다. 네모 안 <b>−</b>는 접기, <b>+</b>는 펼치기입니다.</li>
|
||||
<li>열은 연간 → 1~3월 → 1분기 → 4~6월 → 2분기 → 7~9월 → 3분기 → 10~12월 → 4분기 순서입니다. <b>분기 머리 칸</b>을 누르면 해당 월 3개가 부드럽게 접히거나 펼쳐집니다. 숫자와 글은 펼침이 끝난 뒤 나타납니다. 네모 안 <b>−</b>는 접기, <b>+</b>는 펼치기입니다.</li>
|
||||
<li>어느 행에서든 셀의 <b>오른쪽 경계</b>를 끌어 열 너비를 조절합니다. 경계를 더블클릭하면 가장 긴 문단에 맞춥니다. 직접 넣은 줄바꿈·글자 크기·굵기도 반영합니다.</li>
|
||||
<li>셀 우클릭의 <span class="pjh-ui">현재 열 너비 자동 맞춤</span>·<span class="pjh-ui">전체 열 너비 자동 맞춤</span>도 사용할 수 있습니다. 전체 맞춤은 접힌 월 열까지 포함합니다. 병합 칸은 다른 열을 유지하며 오른쪽 끝 열 너비를 조절합니다.</li>
|
||||
<li>접힘·열 너비는 내 브라우저에 기억됩니다. 행 높이는 가장 높은 글 칸에 맞춰 늘고, 글이 줄면 함께 줄어듭니다. 1열(업무 영역)·2열(항목 이름)은 병합된 칸도 항상 세로 가운데 정렬이며, 목표 내용은 상단 정렬입니다.</li>
|
||||
|
||||
+22
-1
@@ -2321,9 +2321,30 @@ html.pj-goal-selecting .pj-goal-menu-btn { pointer-events: none; }
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.pj-goal-fold-ic, .pj-goal-fold-v { transition: none; }
|
||||
}
|
||||
/* 분기 월 열은 즉시 표시/숨김 — 너비 전환에 따른 숫자 이동·글 재줄바꿈을 방지한다. */
|
||||
/* 분기 접기 — 열은 부드럽게 움직이고, 내용은 최종 너비가 된 뒤 나타난다.
|
||||
원래 폭으로 글 높이를 유지하고, 정렬이 재계산되는 동안 내용만 가려 숫자 밀림을 방지한다. */
|
||||
.pj-goal-table .pj-goal-m { overflow: hidden; }
|
||||
.pj-goal-table .pj-goal-m.is-folding {
|
||||
transition: width .32s ease, min-width .32s ease, max-width .32s ease,
|
||||
padding .32s ease, border-right-width .32s ease;
|
||||
color: transparent !important;
|
||||
}
|
||||
.pj-goal-table .pj-goal-m > :is(.pj-goal-num, .pj-goal-text, .pj-goal-text-ro, .pj-goal-mlabel) {
|
||||
transition: opacity .12s ease;
|
||||
}
|
||||
.pj-goal-table .pj-goal-m.is-folding > :not(.pj-goal-colresize):not(.pj-goal-move-edge) {
|
||||
opacity: 0; transition: none; pointer-events: none;
|
||||
}
|
||||
.pj-goal-table td.pj-goal-m.is-folding > :is(.pj-goal-num, .pj-goal-text, .pj-goal-text-ro) { width: var(--fold-w); }
|
||||
.pj-goal-table thead th.pj-goal-m.is-shrunk,
|
||||
.pj-goal-table td.pj-goal-m.is-shrunk {
|
||||
width: 0; min-width: 0; max-width: 0; padding-left: 0 !important; padding-right: 0 !important; border-right-width: 0;
|
||||
}
|
||||
.pj-goal-table .pj-goal-m.is-gone { display: none; }
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.pj-goal-table .pj-goal-m.is-folding,
|
||||
.pj-goal-table .pj-goal-m > :is(.pj-goal-num, .pj-goal-text, .pj-goal-text-ro, .pj-goal-mlabel) { transition: none; }
|
||||
}
|
||||
|
||||
/* 영역·줄 이름 — 눌러서 그 자리에서 수정(관리자) */
|
||||
.pj-goal-table [data-goal-edit] { cursor: text; border-radius: 5px; padding: 1px 3px; margin: -1px -3px; }
|
||||
|
||||
+32
-8
@@ -8636,6 +8636,13 @@
|
||||
table.querySelectorAll("thead th[data-col]").forEach(function (th) {
|
||||
th.style.setProperty("--cw", colW[th.dataset.col] + "px");
|
||||
});
|
||||
// 접기/펼치기 중에도 글 칸의 자연 높이와 숫자 입력칸의 원래 폭을 유지한다.
|
||||
table.querySelectorAll("td.pj-goal-m[data-month]").forEach(function (td) {
|
||||
const m = parseInt(td.dataset.month, 10), span = parseInt(td.dataset.span || "1", 10);
|
||||
let w = 0;
|
||||
for (let i = m; i < m + span; i++) w += colW["m" + i] || 85;
|
||||
td.style.setProperty("--fold-w", (w - 1) + "px");
|
||||
});
|
||||
}
|
||||
applyColW();
|
||||
let lastColResize = 0;
|
||||
@@ -8685,7 +8692,7 @@
|
||||
});
|
||||
[copy].concat(Array.from(copy.querySelectorAll("*"))).forEach(function (n) {
|
||||
n.removeAttribute("id"); n.removeAttribute("contenteditable"); n.removeAttribute("data-placeholder");
|
||||
n.classList.remove("is-gone");
|
||||
n.classList.remove("is-gone", "is-shrunk", "is-folding");
|
||||
const overrides = { position: "static", width: "max-content", "min-width": "0", "max-width": "none",
|
||||
height: "auto", overflow: "visible", transition: "none", "overflow-wrap": "normal", "word-break": "normal" };
|
||||
Object.keys(overrides).forEach(function (p) { n.style.setProperty(p, overrides[p], "important"); });
|
||||
@@ -8896,10 +8903,12 @@
|
||||
recompute();
|
||||
|
||||
// ── 분기 접기 — 분기 칸 머리의 버튼이 그 분기 월 칸(.pj-goal-m[data-h], 1~4)을 접었다 편다.
|
||||
// 월 칸은 즉시 숨기거나 원래 너비로 표시한다. 너비 애니메이션 중 숫자가 밀리는 현상을 막는다.
|
||||
// 월 열 너비를 애니메이션하되 내용은 완료 뒤 표시해 숫자의 정렬 이동을 감춘다.
|
||||
// 상태는 브라우저에 기억(localStorage pj_goal_fold_q — 반기 때 키 pj_goal_fold 와 따로).
|
||||
// 보기만 하는 사람도 쓸 수 있다.
|
||||
const FOLD_KEY = "pj_goal_fold_q";
|
||||
const FOLD_MS = 320;
|
||||
const foldTimers = {};
|
||||
const QUARTERS = [1, 2, 3, 4];
|
||||
const fold = { 1: false, 2: false, 3: false, 4: false };
|
||||
try {
|
||||
@@ -8921,12 +8930,27 @@
|
||||
delete th.dataset.tip;
|
||||
}
|
||||
}
|
||||
function applyFold(h) {
|
||||
function applyFold(h, animate) {
|
||||
const cells = halfCells(h);
|
||||
const folded = fold[h];
|
||||
clearTimeout(foldTimers[h]);
|
||||
delete foldTimers[h];
|
||||
syncFoldBtn(h);
|
||||
cells.forEach(function (c) { c.classList.toggle("is-gone", folded); });
|
||||
if (!folded) table.querySelectorAll('.pj-goal-m[data-h="' + h + '"] .pj-goal-text').forEach(fit);
|
||||
function finish() {
|
||||
cells.forEach(function (c) {
|
||||
c.classList.toggle("is-gone", folded);
|
||||
c.classList.toggle("is-shrunk", folded);
|
||||
c.classList.remove("is-folding");
|
||||
});
|
||||
if (!folded) table.querySelectorAll('.pj-goal-m[data-h="' + h + '"] .pj-goal-text').forEach(fit);
|
||||
delete foldTimers[h];
|
||||
}
|
||||
const reduce = window.matchMedia && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
||||
if (!animate || reduce) { finish(); return; }
|
||||
cells.forEach(function (c) { c.classList.add("is-folding"); c.classList.remove("is-gone"); });
|
||||
void table.offsetWidth; // 펼침은 너비 0, 접기는 현재 너비에서 시작한다.
|
||||
cells.forEach(function (c) { c.classList.toggle("is-shrunk", folded); });
|
||||
foldTimers[h] = setTimeout(finish, FOLD_MS + 20);
|
||||
}
|
||||
// 분기 머리 칸 아무 곳이나 누르면 접기/펴기(버튼만이 아니라). 너비 조절 손잡이를 끈 뒤의 클릭은 무시.
|
||||
table.querySelectorAll("thead th.pj-goal-fold-th").forEach(function (th) {
|
||||
@@ -8939,7 +8963,7 @@
|
||||
fold[h] = !fold[h];
|
||||
try { localStorage.setItem(FOLD_KEY, JSON.stringify(fold)); } catch (_) {}
|
||||
clearMergeSel();
|
||||
applyFold(h);
|
||||
applyFold(h, true);
|
||||
});
|
||||
});
|
||||
// contenteditable 글 칸은 내용의 자연 높이를 쓴다. 표가 가장 높은 칸에 행을 맞추고
|
||||
@@ -8952,7 +8976,7 @@
|
||||
ta.style.height = ta.scrollHeight + "px";
|
||||
}
|
||||
function fitAll() { table.querySelectorAll(".pj-goal-text").forEach(fit); }
|
||||
QUARTERS.forEach(applyFold);
|
||||
QUARTERS.forEach(function (q) { applyFold(q, false); });
|
||||
|
||||
// 병합 선택(Shift+클릭) — 관리자 전용, 아래에서 채운다. 접기 버튼이 먼저 부르므로 여기 둔다.
|
||||
let clearMergeSel = function () {};
|
||||
@@ -9314,7 +9338,7 @@
|
||||
textSaver.prune();
|
||||
addColHandles();
|
||||
applyColW();
|
||||
QUARTERS.forEach(applyFold);
|
||||
QUARTERS.forEach(function (q) { applyFold(q, false); });
|
||||
bindTexts(table);
|
||||
if (!reduce) {
|
||||
table.querySelectorAll("tbody.pj-goal-area > tr[data-row-id]").forEach(function (tr) {
|
||||
|
||||
@@ -608,8 +608,10 @@ description 을 항상 HTML로 취급하기 때문). 두 번 실행하면 이중
|
||||
- **업무 영역 추가 · 줄 추가는 묻지 않고 바로**(2026-10-02) — 영역은 "새 업무 영역", 줄은 빈 이름으로 만들고 표를 다시 그린 뒤
|
||||
그 이름 칸을 바로 입력 상태로(`editNewName` → `startNameEdit`, Enter 저장 · Esc 그대로).
|
||||
- **분기 접기** — 분기 **머리 칸 아무 곳이나** 누르면(`.pj-goal-fold-th`, 너비 조절 손잡이를 끈 직후 0.3초 클릭은 무시) 그 분기 월 칸을
|
||||
즉시 접었다 편다(`.is-gone` 표시/숨김). 월 열 너비 애니메이션은 사용하지 않아 오른쪽 정렬 숫자가 밀리거나
|
||||
목표 글이 중간에 다시 줄바꿈되지 않는다. 아이콘은 엑셀 열 그룹처럼 네모 안 − (펼침, 누르면 접힘) / + (접힘) — 바뀔 때 90° 돌며 세로 막대가 자라거나 줄어든다.
|
||||
0.32초 동안 부드럽게 접었다 편다. 애니메이션 중에는 해당 월 칸 내용만 가리고, 글 칸은 원래 폭(`--fold-w`)으로
|
||||
높이를 유지한다. 펼침이 끝난 뒤 숫자·글을 표시하므로 오른쪽 정렬 숫자가 밀리지 않는다. 분기별 타이머를 교체해
|
||||
빠른 재클릭·여러 분기 동시 전환도 마지막 상태로 마무리한다. 동작 줄이기 설정에서는 즉시 표시/숨김한다.
|
||||
아이콘은 엑셀 열 그룹처럼 네모 안 − (펼침, 누르면 접힘) / + (접힘) — 바뀔 때 90° 돌며 세로 막대가 자라거나 줄어든다.
|
||||
- **분기 색(monday.com 그룹 색 띠 방식)** — 분기마다 차분한 색 하나(1 파랑 · 2 청록 · 3 보라 · 4 남색, 달성률 빨강·초록과 안 겹치게).
|
||||
`data-h` 가 있는 칸에 `--qc`·`--qt`·`--qt2`. 머리 위 색 띠 = 월 칸 3px · 분기 칸 6px(`th::before`, 월 링크가 덮어도 보임),
|
||||
분기 열 전체 옅은 음영(`td.pj-goal-half-col[data-h]` background-image — 영역 색 위에도), 분기 칸 오른쪽 2px 경계,
|
||||
|
||||
@@ -43,9 +43,16 @@ const server = http.createServer(function (req, res) {
|
||||
try {
|
||||
await new Promise(function (resolve) { server.listen(0, "127.0.0.1", resolve); });
|
||||
browser = await chromium.launch({ headless: true, executablePath: process.env.PJ_TEST_BROWSER || undefined });
|
||||
// 접기/펼치기 첫 화면부터 숫자 위치·저장 너비가 안정적이어야 한다(관리자·보기 전용·75% 배율).
|
||||
// 열 너비는 애니메이션하고, 숫자는 최종 위치에서만 표시한다(관리자·보기 전용·75% 배율).
|
||||
for (const readonly of [false, true]) {
|
||||
const folding = await browser.newPage({ viewport: { width: 1600, height: 1000 } });
|
||||
await folding.addInitScript(() => document.addEventListener("DOMContentLoaded", () => {
|
||||
const row = document.querySelector('tr[data-row-id="10"]');
|
||||
const cell = row.querySelector('td[data-month="1"]');
|
||||
cell.colSpan = 2; cell.dataset.span = "2"; cell.classList.add("is-merged");
|
||||
cell.querySelector("div").textContent = "병합한 목표\n두 번째 줄\n세 번째 줄";
|
||||
row.querySelector('td[data-month="2"]').remove();
|
||||
}));
|
||||
await folding.goto("http://127.0.0.1:" + server.address().port + "/project/goals/2026" + (readonly ? "?readonly" : ""));
|
||||
await folding.evaluate(() => localStorage.setItem("pj_goal_col_w", JSON.stringify({ m1: 150, m2: 110, m3: 175 })));
|
||||
await folding.reload();
|
||||
@@ -56,6 +63,9 @@ const server = http.createServer(function (req, res) {
|
||||
const table = document.getElementById("pj-goal-table");
|
||||
const q = table.querySelector('thead th[data-col="q1"]');
|
||||
const cells = Array.from(table.querySelectorAll('.pj-goal-kpi .pj-goal-m[data-h="1"]'));
|
||||
const merged = table.querySelector('tr[data-row-id="10"] td[data-month="1"]');
|
||||
const mergedHeight = merged.parentElement.getBoundingClientRect().height;
|
||||
const mergedWidth = merged.getBoundingClientRect().width;
|
||||
function snapshot() {
|
||||
return cells.map(c => {
|
||||
const box = c.getBoundingClientRect();
|
||||
@@ -65,32 +75,68 @@ const server = http.createServer(function (req, res) {
|
||||
return [box.x, box.width, content.x, content.width];
|
||||
});
|
||||
}
|
||||
const delay = ms => new Promise(resolve => setTimeout(resolve, ms));
|
||||
async function frames() {
|
||||
const out = [];
|
||||
let heightStable = true;
|
||||
const started = performance.now();
|
||||
while (performance.now() - started < 420) {
|
||||
await new Promise(requestAnimationFrame);
|
||||
out.push(cells.map(c => ({ width: c.getBoundingClientRect().width,
|
||||
folding: c.classList.contains("is-folding"),
|
||||
hidden: c.querySelector(".pj-goal-num") ? getComputedStyle(c.querySelector(".pj-goal-num")).opacity === "0" : getComputedStyle(c).color === "rgba(0, 0, 0, 0)" })));
|
||||
if (merged.classList.contains("is-folding")) {
|
||||
heightStable = heightStable && Math.abs(merged.parentElement.getBoundingClientRect().height - mergedHeight) < 1;
|
||||
}
|
||||
}
|
||||
assertHeightStable = assertHeightStable && heightStable;
|
||||
return out;
|
||||
}
|
||||
let assertHeightStable = true;
|
||||
const before = snapshot();
|
||||
q.click();
|
||||
const hiddenImmediately = cells.every(c => getComputedStyle(c).display === "none");
|
||||
const closing = await frames();
|
||||
await delay(100);
|
||||
const hiddenAfterClose = cells.every(c => getComputedStyle(c).display === "none");
|
||||
q.click();
|
||||
const frames = [snapshot()];
|
||||
for (let i = 0; i < 6; i++) {
|
||||
await new Promise(requestAnimationFrame); frames.push(snapshot());
|
||||
}
|
||||
// 기존 애니메이션 종료 시점에도 폭·숫자 위치가 바뀌지 않아야 한다.
|
||||
await new Promise(resolve => setTimeout(resolve, 400)); frames.push(snapshot());
|
||||
q.click(); q.click(); q.click();
|
||||
const opening = await frames();
|
||||
await delay(150);
|
||||
const after = snapshot();
|
||||
// 여러 분기 동시 전환과 빠른 반전: 마지막 클릭 상태만 남는다.
|
||||
const q2 = table.querySelector('thead th[data-col="q2"]');
|
||||
q.click(); q2.click(); await delay(70); q.click(); await delay(50); q.click();
|
||||
await delay(400);
|
||||
const rapidHidden = cells.every(c => getComputedStyle(c).display === "none");
|
||||
const otherHidden = Array.from(table.querySelectorAll('.pj-goal-m[data-h="2"]')).every(c => getComputedStyle(c).display === "none");
|
||||
const savedFold = JSON.parse(localStorage.getItem("pj_goal_fold_q"))[1];
|
||||
q.click();
|
||||
return { before, frames, hiddenImmediately, rapidHidden, savedFold,
|
||||
q.click(); q2.click(); await delay(500);
|
||||
return { before, after, closing, opening, hiddenAfterClose, rapidHidden, otherHidden, savedFold,
|
||||
mergedStable: assertHeightStable && Math.abs(merged.getBoundingClientRect().width - mergedWidth) < 0.1 && merged.colSpan === 2,
|
||||
clean: !table.querySelector(".is-folding"),
|
||||
widths: ["m1", "m2", "m3"].map(key => table.querySelector('thead th[data-col="' + key + '"]').getBoundingClientRect().width / zoom) };
|
||||
}, zoom);
|
||||
assert(result.hiddenImmediately && result.rapidHidden && result.savedFold, JSON.stringify(result));
|
||||
result.frames.forEach(frame => frame.forEach((cell, i) => cell.forEach((value, j) => {
|
||||
assert(result.hiddenAfterClose && result.rapidHidden && result.otherHidden && result.savedFold && result.clean && result.mergedStable,
|
||||
JSON.stringify({ hiddenAfterClose: result.hiddenAfterClose, rapidHidden: result.rapidHidden, otherHidden: result.otherHidden, savedFold: result.savedFold, clean: result.clean, mergedStable: result.mergedStable }));
|
||||
for (const frames of [result.closing, result.opening]) {
|
||||
assert(frames.some(frame => frame[0].width > 1 && frame[0].width < result.before[0][1] - 1), "quarter width must visibly animate");
|
||||
frames.forEach(frame => frame.forEach(cell => assert(!cell.folding || cell.hidden, "moving numeric content must stay hidden")));
|
||||
}
|
||||
result.after.forEach((cell, i) => cell.forEach((value, j) => {
|
||||
assert(Math.abs(value - result.before[i][j]) < 0.1, "quarter numeric position changed during reveal");
|
||||
})));
|
||||
}));
|
||||
result.widths.forEach((width, i) => assert(Math.abs(width - [150, 110, 175][i]) < 1));
|
||||
}
|
||||
await folding.emulateMedia({ reducedMotion: "reduce" });
|
||||
const reduced = await folding.evaluate(() => {
|
||||
const table = document.getElementById("pj-goal-table"), q = table.querySelector('thead th[data-col="q1"]');
|
||||
const cells = Array.from(table.querySelectorAll('.pj-goal-m[data-h="1"]'));
|
||||
q.click(); const hidden = cells.every(c => getComputedStyle(c).display === "none");
|
||||
q.click(); return hidden && cells.every(c => getComputedStyle(c).display !== "none") && !table.querySelector(".is-folding");
|
||||
});
|
||||
assert(reduced, "reduced motion uses immediate toggles");
|
||||
await folding.close();
|
||||
}
|
||||
console.log("PASS instant quarter reveal keeps numeric positions, saved widths and rapid-toggle state at 100%/75%");
|
||||
console.log("PASS animated quarter widths with stable numeric reveal, saved widths and concurrent/rapid toggles at 100%/75%");
|
||||
const page = await browser.newPage({ viewport: { width: 1600, height: 1000 } });
|
||||
const errors = [], writes = [];
|
||||
page.on("pageerror", function (e) { errors.push(e.message); });
|
||||
|
||||
@@ -604,10 +604,11 @@ function meetServer(env, st) {
|
||||
// 분기 접기는 보기 전용도
|
||||
const qth = env.d.querySelector('th.pj-goal-fold-th[data-h="1"]');
|
||||
qth.dispatchEvent(new env.w.MouseEvent("click", { bubbles: true }));
|
||||
check("[회귀] 분기 머리 클릭 → 즉시 접힘(보기 전용도)", qth.classList.contains("is-folded") && env.d.querySelector('td.pj-goal-m[data-h="1"]').classList.contains("is-gone"));
|
||||
check("[회귀] 분기 머리 클릭 → 접기 애니메이션(보기 전용도)", qth.classList.contains("is-folded") && env.d.querySelector('td.pj-goal-m[data-h="1"]').classList.contains("is-shrunk"));
|
||||
check("[회귀] 접기 상태 기억", /"1":true/.test(env.w.localStorage.getItem("pj_goal_fold_q") || ""));
|
||||
qth.dispatchEvent(new env.w.MouseEvent("click", { bubbles: true }));
|
||||
check("[회귀] 분기 머리 재클릭 → 즉시 펼침", !qth.classList.contains("is-folded") && !env.d.querySelector('td.pj-goal-m[data-h="1"]').classList.contains("is-gone"));
|
||||
await wait(380);
|
||||
check("[회귀] 분기 머리 재클릭 → 펼침 완료·오래된 타이머 취소", !qth.classList.contains("is-folded") && !env.d.querySelector('td.pj-goal-m[data-h="1"]').classList.contains("is-gone") && !env.d.querySelector('td.pj-goal-m[data-h="1"]').classList.contains("is-folding"));
|
||||
});
|
||||
await section(async function () { // 회귀 — 열 너비 끌기·고정 열 변수·스크롤 위치 되살리기
|
||||
const env = makeEnv(PAGE.goals_admin, GOALS_URL, { session: { pj_goal_scroll: JSON.stringify(["/project/goals/2026", 120, 45]) } });
|
||||
|
||||
Reference in New Issue
Block a user