2026-10-13 12:43:34 +00:00
|
|
|
// Module ID: 13084
|
|
|
|
|
// Function ID: 13085
|
2026-09-10 05:38:07 +00:00
|
|
|
// Name: setUserStatus
|
2026-10-13 12:43:34 +00:00
|
|
|
// Dependencies: [5, 6805, 5759, 1085, 4962, 1126, 13085, 2046, 1240, 4970, 1265, 2]
|
2026-07-20 16:05:17 +00:00
|
|
|
// Exports: default
|
|
|
|
|
|
2026-10-13 12:43:34 +00:00
|
|
|
// Module 13084 (setUserStatus)
|
2026-10-03 08:58:59 +00:00
|
|
|
import Constants from "Constants" /* 1085 */;
|
|
|
|
|
import _asyncToGenerator from "_asyncToGenerator" /* 5 */;
|
2026-10-12 06:59:38 +00:00
|
|
|
import LastMentionTimestampStore from "LastMentionTimestampStore" /* 6805 */;
|
2026-10-10 08:08:14 +00:00
|
|
|
import SelfPresenceStore from "SelfPresenceStore" /* 5759 */;
|
2026-10-03 08:58:59 +00:00
|
|
|
import size from "module_2" /* 2 */;
|
2026-07-23 10:11:24 +00:00
|
|
|
|
2026-10-03 08:58:59 +00:00
|
|
|
let closure_2, prev_status, statusCreatedAtMs;
|
|
|
|
|
|
|
|
|
|
let obj = function _setUserStatus() {
|
|
|
|
|
obj = _asyncToGenerator(async (next_status) => {
|
|
|
|
|
let c3 = 0;
|
|
|
|
|
let c4 = 0;
|
|
|
|
|
const iter = (async (arg0) => {
|
|
|
|
|
let c0;
|
|
|
|
|
let c2;
|
|
|
|
|
let closure_1;
|
|
|
|
|
let disableTracking;
|
|
|
|
|
let result;
|
|
|
|
|
let statusExpiresAtMs;
|
|
|
|
|
let tmp;
|
|
|
|
|
function getStatusUpdateAnnouncement(c0, arg1) {
|
|
|
|
|
obj = value(closure_1_2[4]);
|
|
|
|
|
const humanizeStatusResult = obj.humanizeStatus(c0);
|
|
|
|
|
if ("0" === arg1) {
|
|
|
|
|
const intl3 = tmp(tmp2[5]).intl;
|
|
|
|
|
const obj2 = { statusLabel: humanizeStatusResult };
|
|
|
|
|
return intl3.formatToPlainString(value(closure_1_2[5]).t.dO2aLi, obj2);
|
2026-10-01 06:55:13 +00:00
|
|
|
} else {
|
2026-10-03 08:58:59 +00:00
|
|
|
let formatToPlainStringResult;
|
|
|
|
|
const tmpResult = value(closure_1_2[6]);
|
|
|
|
|
const statusExpiryParts = tmpResult.getStatusExpiryParts(arg1);
|
|
|
|
|
const timeString = statusExpiryParts.timeString;
|
|
|
|
|
if ("today" === statusExpiryParts.kind) {
|
|
|
|
|
const intl2 = tmp(tmp2[5]).intl;
|
|
|
|
|
const obj3 = { statusLabel: humanizeStatusResult, timeString };
|
|
|
|
|
formatToPlainStringResult = intl2.formatToPlainString(tmp(tmp2[5]).t["r50t/S"], obj3);
|
|
|
|
|
} else {
|
|
|
|
|
const intl = tmp(tmp2[5]).intl;
|
|
|
|
|
const obj4 = { statusLabel: humanizeStatusResult, dateString: tmp6, timeString };
|
|
|
|
|
formatToPlainStringResult = intl.formatToPlainString(tmp(tmp2[5]).t["J+GJHv"], obj4);
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
return formatToPlainStringResult;
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
}
|
|
|
|
|
if (null == prev_status) {
|
|
|
|
|
prev_status = closure_130_5.getStatus();
|
|
|
|
|
}
|
|
|
|
|
let str = "0";
|
|
|
|
|
if (null != c3) {
|
|
|
|
|
const _Date = Date;
|
|
|
|
|
const _HermesInternal = HermesInternal;
|
|
|
|
|
str = "" + Date.now() + c3;
|
|
|
|
|
}
|
|
|
|
|
const PreloadedUserSettingsActionCreators = closure_130_0(closure_130_2[7]).PreloadedUserSettingsActionCreators;
|
|
|
|
|
await PreloadedUserSettingsActionCreators.updateAsync("status", async (statusCreatedAtMs) => {
|
|
|
|
|
const StringValue = value(closure_2[8]).StringValue;
|
|
|
|
|
obj = { value };
|
|
|
|
|
statusCreatedAtMs.status = StringValue.create(obj);
|
|
|
|
|
statusCreatedAtMs.statusExpiresAtMs = statusExpiresAtMs;
|
|
|
|
|
const tmp = value;
|
|
|
|
|
const tmp2 = closure_2;
|
|
|
|
|
if (prev_status === value) {
|
|
|
|
|
if (null != statusCreatedAtMs.statusCreatedAtMs) {
|
|
|
|
|
statusCreatedAtMs = statusCreatedAtMs.statusCreatedAtMs;
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
statusCreatedAtMs.statusCreatedAtMs = statusCreatedAtMs;
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
const UInt64Value = tmp(tmp2[8]).UInt64Value;
|
|
|
|
|
const obj2 = { value: "" + Date.now() };
|
|
|
|
|
statusCreatedAtMs = UInt64Value.create(obj2);
|
|
|
|
|
}, closure_130_0(closure_130_2[7]).UserSettingsDelay.INFREQUENT_USER_ACTION);
|
|
|
|
|
let closure_6 = getStatusUpdateAnnouncement(next_status, str);
|
|
|
|
|
const AccessibilityAnnouncer = closure_130_0(closure_130_2[9]).AccessibilityAnnouncer;
|
|
|
|
|
AccessibilityAnnouncer.announce(closure_6);
|
|
|
|
|
const tmp65 = disableTracking;
|
|
|
|
|
if (!tmp65) {
|
|
|
|
|
const tmp6 = closure_2;
|
|
|
|
|
obj = { next_status, prev_status };
|
|
|
|
|
const merged = Object.assign(closure_130_4.getGlobalStats());
|
|
|
|
|
let obj9 = obj;
|
|
|
|
|
if (null != c3) {
|
|
|
|
|
const obj8 = { expire_duration_minutes: result };
|
|
|
|
|
const merged1 = Object.assign(obj9);
|
|
|
|
|
result = null;
|
|
|
|
|
if (null != c3) {
|
|
|
|
|
result = c3 / 60000;
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
obj9 = obj8;
|
|
|
|
|
}
|
|
|
|
|
if (null != c2) {
|
|
|
|
|
obj9 = {};
|
|
|
|
|
const merged2 = Object.assign(obj9);
|
|
|
|
|
const merged3 = Object.assign(c2);
|
2026-10-01 06:55:13 +00:00
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
let obj4 = closure_130_1(closure_130_2[10]);
|
|
|
|
|
obj4.track(closure_130_6.USER_STATUS_UPDATED, obj9);
|
|
|
|
|
}
|
|
|
|
|
await "IconComponent";
|
|
|
|
|
closure_2 = tmp4;
|
|
|
|
|
prev_status = tmp;
|
|
|
|
|
({ nextStatus: c0, prevStatus: closure_1, analyticsContext: c2, durationMillis: c3, disableTracking } = value);
|
|
|
|
|
if (disableTracking === undefined) {
|
|
|
|
|
disableTracking = false;
|
2026-09-10 05:38:07 +00:00
|
|
|
}
|
2026-10-09 10:00:15 +00:00
|
|
|
return "Set";
|
2026-10-03 08:58:59 +00:00
|
|
|
})();
|
|
|
|
|
iter.next();
|
|
|
|
|
return iter;
|
|
|
|
|
});
|
|
|
|
|
return obj(...arguments);
|
2026-09-10 05:38:07 +00:00
|
|
|
};
|
2026-10-03 08:58:59 +00:00
|
|
|
const AnalyticEvents = Constants.AnalyticEvents;
|
2026-09-10 05:38:07 +00:00
|
|
|
let result = size.fileFinishedImporting("modules/multi_account/setUserStatus.tsx");
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
export default function setUserStatus() {
|
2026-10-03 08:58:59 +00:00
|
|
|
return obj(...arguments);
|
2026-07-20 16:05:17 +00:00
|
|
|
};
|