mirror of
https://github.com/SableClient/Sable.git
synced 2026-11-27 04:16:25 -08:00
Search, create room, create space, and bug report open as full-screen pages on mobile via useOpen*Modal hooks checking useScreenSizeContext. Desktop modal flow unchanged. Adds full-screen room/space settings with shared section layout and swipe-back navigation. Adds tauri-plugin-sharekit (v0.4.0-rc.5) for iOS/Android system share sheet, with a shareText() util that falls back to Web Share API then clipboard. Wired into ShareChip, Space menu, SpaceTabs menu. Syncs Cargo.lock with the new sharekit dependency and relaxes the edge-to-edge inset contract test to match the wired plugin via .plugin(tauri_plugin_edge_to_edge::init()) so chaining sharekit onto the same mobile builder no longer breaks the test.
19 lines
588 B
TypeScript
19 lines
588 B
TypeScript
import { render } from '@testing-library/react';
|
|
import { describe, expect, it, vi } from 'vitest';
|
|
import { ScreenSize, ScreenSizeProvider } from '$hooks/useScreenSize';
|
|
import { Modal500 } from './Modal500';
|
|
|
|
describe('Modal500', () => {
|
|
it('does not throw when rendered without tabbable children', () => {
|
|
expect(() =>
|
|
render(
|
|
<ScreenSizeProvider value={ScreenSize.Desktop}>
|
|
<Modal500 requestClose={vi.fn<() => void>()}>
|
|
<div>Empty modal content</div>
|
|
</Modal500>
|
|
</ScreenSizeProvider>
|
|
)
|
|
).not.toThrow();
|
|
});
|
|
});
|