Skip to content

Conversation

@dwelle
Copy link
Member

@dwelle dwelle commented May 19, 2024

Honestly not sure if this is the root cause of the problem and thus will fix it, but it makes sense to me. We'll see.

Assumption: chrome frees up memory wherever it can (they're quite aggressive lately), and one such thing is clearing the canvas context when the tab is inactive.

If true, this PR rerender the canvas on focus.

@vercel
Copy link

vercel bot commented May 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
excalidraw ✅ Ready (Inspect) Visit Preview May 19, 2024 4:21pm
excalidraw-package-example ✅ Ready (Inspect) Visit Preview May 19, 2024 4:21pm
excalidraw-package-example-with-nextjs ✅ Ready (Inspect) Visit Preview May 19, 2024 4:21pm
1 Ignored Deployment
Name Status Preview Updated (UTC)
docs ⬜️ Ignored (Inspect) May 19, 2024 4:21pm

@github-actions
Copy link

Coverage Report

Status Category Percentage Covered / Total
🔴 Lines 65.56% (🎯 70%) 51254 / 78176
🔴 Statements 65.56% (🎯 70%) 51254 / 78176
🔴 Functions 66.63% (🎯 68%) 1564 / 2347
🟢 Branches 80.99% (🎯 70%) 6294 / 7771
File Coverage
File Stmts % Branch % Funcs % Lines Uncovered Lines
Changed Files
packages/excalidraw/components/App.tsx 69.51% 76.54% 67.87% 69.51% 474-475, 582-591, 690-691, 709-710, 731-791, 794-800, 803-806, 809-885, 888-907, 910-915, 923-933, 935-936, 941-942, 946-948, 962, 969-1230, 1290-1291, 1302-1303, 1331-1333, 1343-1388, 1414, 1424, 1431-1434, 1443-1447, 1478-1479, 1563-1573, 1578-1593, 1597-1644, 1716-1721, 1750-1755, 1758-1788, 1796-1821, 1824-1833, 1836-1948, 1951-1959, 1968-1981, 1984-2010, 2013-2084, 2087-2128, 2180-2181, 2195-2196, 2223-2224, 2228-2229, 2249-2257, 2262-2275, 2281-2282, 2287-2295, 2297-2305, 2317, 2358-2359, 2381-2382, 2389, 2458-2460, 2463-2468, 2473-2474, 2513-2521, 2526-2535, 2573-2574, 2661-2662, 2666, 2669-2670, 2678-2681, 2690-2703, 2709-2712, 2715, 2717-2718, 2725-2726, 2732-2733, 2736-2737, 2745-2746, 2749-2750, 2753-2756, 2767-2775, 2780-2781, 2831-2832, 2846-2852, 2858-2866, 2870-2878, 2882-2883, 2886-2919, 2922-2934, 2945-2946, 2957-2958, 2975-2979, 2983-2986, 2993-2995, 3013-3020, 3023, 3025-3030, 3034-3036, 3057-3058, 3065-3067, 3069-3092, 3118, 3124, 3180-3181, 3198-3200, 3222-3223, 3229-3232, 3238-3319, 3391-3392, 3451, 3461-3479, 3482-3488, 3491-3492, 3498-3511, 3597-3598, 3600-3601, 3606-3608, 3616-3617, 3640-3654, 3659-3678, 3730-3731, 3810, 3819-3820, 3822-3829, 3844-3848, 3859-3860, 3863-3867, 3869-3870, 3872-3875, 3900-3901, 3910-3912, 3914, 3997-4000, 4022-4024, 4034-4035, 4037-4057, 4060-4066, 4083-4086, 4092-4095, 4105-4112, 4152-4156, 4160, 4165-4166, 4171-4175, 4208-4209, 4212-4213, 4216-4217, 4225-4229, 4234-4235, 4241-4251, 4256-4283, 4288-4299, 4363, 4389-4390, 4455-4461, 4544, 4569, 4595-4597, 4664-4665, 4680-4681, 4851-4852, 4855-4856, 4864, 4913-4917, 4968-4975, 4981-5047, 5091, 5143, 5170, 5177-5178, 5187-5190, 5221, 5269-5272, 5275-5281, 5283-5286, 5301-5310, 5313-5314, 5414-5415, 5418, 5420-5425, 5431-5433, 5435, 5444, 5466-5471, 5473-5476, 5480-5481, 5491-5591, 5595-5596, 5611-5612, 5645-5646, 5673-5674, 5707-5734, 5741-5742, 5764-5765, 5784, 5786-5829, 5834-5835, 5837-5838, 5854-5855, 5861-5862, 5866-5869, 5872-5873, 5888-5915, 5923-5924, 5928-5931, 5933-5937, 5955-5959, 6005-6010, 6012-6014, 6030, 6032-6045, 6070-6073, 6117, 6134-6135, 6137-6160, 6175-6176, 6287-6315, 6421-6422, 6442-6443, 6537, 6543-6544, 6567-6586, 6601, 6729, 6751-6789, 6793-6843, 6858, 6867, 6901-6907, 6922-6924, 7066-7069, 7093-7124, 7137, 7139-7147, 7161, 7163-7171, 7178-7181, 7189-7194, 7221-7222, 7227-7229, 7232-7233, 7258-7259, 7290-7291, 7374-7375, 7424-7437, 7503-7506, 7532-7533, 7569-7570, 7583, 7601-7607, 7614-7617, 7640-7646, 7718, 7724, 7739-7746, 7749-7756, 7812, 7889-7890, 7911-7913, 7916, 7930-7954, 8060-8084, 8094-8133, 8146-8147, 8156-8163, 8177-8190, 8203-8210, 8264-8290, 8292-8293, 8367-8368, 8375, 8377-8413, 8442, 8503, 8535-8537, 8562-8567, 8569-8570, 8575-8577, 8580-8600, 8614-8615, 8621-8630, 8635, 8639-8643, 8652-8656, 8659-8664, 8668-8675, 8705, 8707-8711, 8713-8723, 8739-8741, 8752-8760, 8764-8808, 8811-8882, 8890, 8908-8915, 8917-8933, 8948-8970, 8989-8991, 9036-9037, 9151-9155, 9157-9173, 9175-9179, 9191-9192, 9202-9218, 9237-9256, 9258-9259, 9286-9287, 9291-9292, 9302, 9304-9307, 9309-9310, 9350, 9371-9372, 9398, 9401, 9442, 9454-9462, 9479-9480, 9512-9515, 9608-9615, 9641-9642, 9685-9739, 9787-9788, 9797-9800, 9805-9806, 9827-9829, 9831-9835, 9873
Generated in workflow #2533

@dwelle dwelle merged commit 1b6e3fe into master May 19, 2024
@dwelle dwelle deleted the dwelle/rerender-on-focus branch May 19, 2024 20:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants