Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,14 @@ function App() {
const handleKeyPress = useCallback(
(event: any) => {
if (event.key === 'F10') {
handle.enter();
try {
const promise = handle.enter();
if (promise && promise.catch) {
promise.catch((err: any) => console.warn('Fullscreen error:', err));
}
} catch (err) {
console.warn('Fullscreen error:', err);
}
} else if (event.key === 'Escape') {
handle.exit();
}
Expand All @@ -23,7 +30,14 @@ function App() {
useEffect(() => {
const enterFullScreen = () => {
if (!handle.active) {
handle.enter();
try {
const promise = handle.enter();
if (promise && promise.catch) {
promise.catch((err: any) => console.warn('Fullscreen error:', err));
}
} catch (err) {
console.warn('Fullscreen error:', err);
}
}
};

Expand Down
2 changes: 2 additions & 0 deletions src/localization/locales/en/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
"loginPasswordText1": "Touch ID or Enter password",
"loginPasswordText2": "Your password is required to enable Touch ID",
"inputPlaceholder": "Enter Password",
"passwordHintLabel": "Password Hint",
"passwordHint": "Your password is the same as your macOS user account password. If you've forgotten it, try entering your Apple ID password or use the Reset Password assistant. Please use - 'Amit'",
"keyboard": {
"type": "ABC - India",
"option": {
Expand Down
13 changes: 10 additions & 3 deletions src/screens/public/Lock/component/TimeDate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,14 @@ const MemoisedTimeComponent = React.memo(TimeComponent);
const MemoisedDateComponent = React.memo(DateComponent);

const TimeDateComponent = () => {
const { date, time } = uiStore(useShallow(dateTimeSelector));
const { dateObject } = uiStore(useShallow(dateTimeSelector));

const formattedDate = dateObject?.toDateString().slice(0, 10) ?? '';
const formattedTime = dateObject?.toLocaleTimeString([], {
hour: '2-digit',
minute: '2-digit',
hour12: false,
}) ?? '';

return (
<Box
Expand All @@ -36,8 +43,8 @@ const TimeDateComponent = () => {
zIndex={0}
aria-label="time-date-component"
>
<MemoisedDateComponent date={date?.slice(0, 10) ?? ''} />
<MemoisedTimeComponent time={time?.slice(0, 5) ?? ''} />
<MemoisedDateComponent date={formattedDate} />
<MemoisedTimeComponent time={formattedTime} />
</Box>
);
};
Expand Down
Loading
Loading