feat(mobile): add all pages for video editor

This commit is contained in:
Prateek Sunal
2024-05-30 22:38:05 +05:30
parent fae54faffc
commit bfa652df36
30 changed files with 886 additions and 524 deletions

View File

@@ -0,0 +1,13 @@
<svg width="40" height="41" viewBox="0 0 40 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_26160_90150)">
<path d="M8.5 12.2266V11.9266C8.5 10.8065 8.5 10.2464 8.71799 9.81858C8.90973 9.44226 9.21569 9.1363 9.59202 8.94455C10.0198 8.72656 10.5799 8.72656 11.7 8.72656H12" stroke="white" stroke-linecap="round"/>
<path d="M28 8.72656H28.3C29.4201 8.72656 29.9802 8.72656 30.408 8.94455C30.7843 9.1363 31.0903 9.44226 31.282 9.81858C31.5 10.2464 31.5 10.8065 31.5 11.9266V12.2266" stroke="white" stroke-linecap="round"/>
<path d="M31.5 28.2266V28.5266C31.5 29.6467 31.5 30.2067 31.282 30.6345C31.0903 31.0109 30.7843 31.3168 30.408 31.5086C29.9802 31.7266 29.4201 31.7266 28.3 31.7266H28" stroke="white" stroke-linecap="round"/>
<path d="M8.5 28.2266V28.5266C8.5 29.6467 8.5 30.2067 8.71799 30.6345C8.90973 31.0109 9.21569 31.3168 9.59202 31.5086C10.0198 31.7266 10.5799 31.7266 11.7 31.7266H12" stroke="white" stroke-linecap="round"/>
</g>
<defs>
<clipPath id="clip0_26160_90150">
<rect width="24" height="24" fill="white" transform="translate(8 8.22656)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -0,0 +1,10 @@
<svg width="40" height="41" viewBox="0 0 40 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_26160_90098)">
<path d="M23 16.2266V24.2266H13V16.2266H23ZM24 14.2266H12C11.45 14.2266 11 14.6766 11 15.2266V25.2266C11 25.7766 11.45 26.2266 12 26.2266H24C24.55 26.2266 25 25.7766 25 25.2266V21.7266L29 25.7266V14.7266L25 18.7266V15.2266C25 14.6766 24.55 14.2266 24 14.2266Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_26160_90098">
<rect width="24" height="24" fill="white" transform="translate(8 8.22656)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 562 B

View File

@@ -0,0 +1,7 @@
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M6 12.5V12.2C6 11.0799 6 10.5198 6.21799 10.092C6.40973 9.71569 6.71569 9.40973 7.09202 9.21799C7.51984 9 8.07989 9 9.2 9H9.5" stroke="white" stroke-linecap="round"/>
<path d="M30.5 9H30.8C31.9201 9 32.4802 9 32.908 9.21799C33.2843 9.40973 33.5903 9.71569 33.782 10.092C34 10.5198 34 11.0799 34 12.2V12.5" stroke="white" stroke-linecap="round"/>
<path d="M34 28.5V28.8C34 29.9201 34 30.4802 33.782 30.908C33.5903 31.2843 33.2843 31.5903 32.908 31.782C32.4802 32 31.9201 32 30.8 32H30.5" stroke="white" stroke-linecap="round"/>
<path d="M6 28.5V28.8C6 29.9201 6 30.4802 6.21799 30.908C6.40973 31.2843 6.71569 31.5903 7.09202 31.782C7.51984 32 8.07989 32 9.2 32H9.5" stroke="white" stroke-linecap="round"/>
<path d="M11.8253 16.2727V25H10.2443V17.8111H10.1932L8.15199 19.1151V17.6662L10.321 16.2727H11.8253ZM17.2372 25.1193C16.8196 25.1165 16.4119 25.044 16.0142 24.902C15.6165 24.7571 15.2585 24.5227 14.9403 24.1989C14.6222 23.8722 14.3693 23.4389 14.1818 22.8991C13.9943 22.3565 13.902 21.6847 13.9048 20.8835C13.9048 20.1364 13.9844 19.4702 14.1435 18.8849C14.3026 18.2997 14.5312 17.8054 14.8295 17.402C15.1278 16.9957 15.4872 16.6861 15.9077 16.473C16.331 16.2599 16.804 16.1534 17.3267 16.1534C17.875 16.1534 18.3608 16.2614 18.7841 16.4773C19.2102 16.6932 19.554 16.9886 19.8153 17.3636C20.0767 17.7358 20.2386 18.1562 20.3011 18.625H18.7457C18.6662 18.2898 18.5028 18.0227 18.2557 17.8239C18.0114 17.6222 17.7017 17.5213 17.3267 17.5213C16.7216 17.5213 16.2557 17.7841 15.929 18.3097C15.6051 18.8352 15.4418 19.5568 15.4389 20.4744H15.4986C15.6378 20.2244 15.8182 20.0099 16.0398 19.831C16.2614 19.652 16.5114 19.5142 16.7898 19.4176C17.071 19.3182 17.3679 19.2685 17.6804 19.2685C18.1918 19.2685 18.6506 19.3906 19.0568 19.6349C19.4659 19.8793 19.7898 20.2159 20.0284 20.6449C20.267 21.071 20.3849 21.5597 20.3821 22.1108C20.3849 22.6847 20.2543 23.2003 19.9901 23.6577C19.7259 24.1122 19.358 24.4702 18.8864 24.7315C18.4148 24.9929 17.8651 25.1222 17.2372 25.1193ZM17.2287 23.8409C17.5384 23.8409 17.8153 23.7656 18.0597 23.6151C18.304 23.4645 18.4972 23.2614 18.6392 23.0057C18.7813 22.75 18.8509 22.4631 18.848 22.1449C18.8509 21.8324 18.7827 21.5497 18.6435 21.2969C18.5071 21.044 18.3182 20.8437 18.0767 20.696C17.8352 20.5483 17.5597 20.4744 17.25 20.4744C17.0199 20.4744 16.8054 20.5185 16.6065 20.6065C16.4077 20.6946 16.2344 20.8168 16.0866 20.973C15.9389 21.1264 15.8224 21.3054 15.7372 21.5099C15.6548 21.7116 15.6122 21.9276 15.6094 22.1577C15.6122 22.4616 15.6832 22.7415 15.8224 22.9972C15.9616 23.2528 16.1534 23.4574 16.3977 23.6108C16.642 23.7642 16.919 23.8409 17.2287 23.8409ZM22.7898 23.9517C22.5313 23.9517 22.3097 23.8608 22.125 23.679C21.9403 23.4943 21.8494 23.2727 21.8523 23.0142C21.8494 22.7585 21.9403 22.5398 22.125 22.358C22.3097 22.1761 22.5313 22.0852 22.7898 22.0852C23.0398 22.0852 23.2571 22.1761 23.4418 22.358C23.6293 22.5398 23.7244 22.7585 23.7273 23.0142C23.7244 23.1875 23.679 23.3452 23.5909 23.4872C23.5057 23.6293 23.392 23.7429 23.25 23.8281C23.1108 23.9105 22.9574 23.9517 22.7898 23.9517ZM22.7898 19.6264C22.5313 19.6264 22.3097 19.5355 22.125 19.3537C21.9403 19.169 21.8494 18.9474 21.8523 18.6889C21.8494 18.4332 21.9403 18.2145 22.125 18.0327C22.3097 17.848 22.5313 17.7557 22.7898 17.7557C23.0398 17.7557 23.2571 17.848 23.4418 18.0327C23.6293 18.2145 23.7244 18.4332 23.7273 18.6889C23.7244 18.8594 23.679 19.0156 23.5909 19.1577C23.5057 19.2997 23.392 19.4134 23.25 19.4986C23.1108 19.5838 22.9574 19.6264 22.7898 19.6264ZM28.3327 16.1534C28.7504 16.1562 29.1566 16.2301 29.5515 16.375C29.9492 16.517 30.3072 16.75 30.6254 17.0739C30.9435 17.3949 31.1964 17.8253 31.3839 18.3651C31.5714 18.9048 31.6651 19.5724 31.6651 20.3679C31.668 21.1179 31.5884 21.7884 31.4265 22.3793C31.2674 22.9673 31.0387 23.4645 30.7404 23.8707C30.4421 24.277 30.0827 24.5866 29.6623 24.7997C29.2418 25.0128 28.7688 25.1193 28.2433 25.1193C27.6921 25.1193 27.2035 25.0114 26.7773 24.7955C26.354 24.5795 26.0117 24.2841 25.7504 23.9091C25.489 23.5341 25.3285 23.1051 25.2688 22.6222H26.8242C26.9038 22.9687 27.0657 23.2443 27.31 23.4489C27.5572 23.6506 27.8683 23.7514 28.2433 23.7514C28.8484 23.7514 29.3143 23.4886 29.641 22.9631C29.9677 22.4375 30.131 21.7074 30.131 20.7727H30.0714C29.9322 21.0227 29.7518 21.2386 29.5302 21.4205C29.3086 21.5994 29.0572 21.7372 28.7759 21.8338C28.4975 21.9304 28.2021 21.9787 27.8896 21.9787C27.3782 21.9787 26.918 21.8565 26.5089 21.6122C26.1026 21.3679 25.7802 21.0327 25.5415 20.6065C25.3058 20.1804 25.1864 19.6932 25.1836 19.1449C25.1836 18.5767 25.3143 18.0668 25.5756 17.6151C25.8398 17.1605 26.2077 16.8026 26.6793 16.5412C27.1509 16.277 27.7021 16.1477 28.3327 16.1534ZM28.337 17.4318C28.0302 17.4318 27.7532 17.5071 27.506 17.6577C27.2617 17.8054 27.0685 18.0071 26.9265 18.2628C26.7873 18.5156 26.7177 18.7983 26.7177 19.1108C26.7205 19.4205 26.7901 19.7017 26.9265 19.9545C27.0657 20.2074 27.2546 20.4077 27.4933 20.5554C27.7347 20.7031 28.0103 20.777 28.32 20.777C28.5501 20.777 28.7646 20.733 28.9634 20.6449C29.1623 20.5568 29.3356 20.4347 29.4833 20.2784C29.6339 20.1193 29.7504 19.9389 29.8327 19.7372C29.918 19.5355 29.9592 19.3224 29.9563 19.098C29.9563 18.7997 29.8853 18.5241 29.7433 18.2713C29.604 18.0185 29.4123 17.8153 29.168 17.6619C28.9265 17.5085 28.6495 17.4318 28.337 17.4318Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 5.3 KiB

View File

@@ -0,0 +1,14 @@
<svg width="40" height="41" viewBox="0 0 40 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_26160_90104)">
<path d="M8.5 12.2266V11.9266C8.5 10.8065 8.5 10.2464 8.71799 9.81858C8.90973 9.44226 9.21569 9.1363 9.59202 8.94455C10.0198 8.72656 10.5799 8.72656 11.7 8.72656H12" stroke="white" stroke-linecap="round"/>
<path d="M28 8.72656H28.3C29.4201 8.72656 29.9802 8.72656 30.408 8.94455C30.7843 9.1363 31.0903 9.44226 31.282 9.81858C31.5 10.2464 31.5 10.8065 31.5 11.9266V12.2266" stroke="white" stroke-linecap="round"/>
<path d="M31.5 28.2266V28.5266C31.5 29.6467 31.5 30.2067 31.282 30.6345C31.0903 31.0109 30.7843 31.3168 30.408 31.5086C29.9802 31.7266 29.4201 31.7266 28.3 31.7266H28" stroke="white" stroke-linecap="round"/>
<path d="M8.5 28.2266V28.5266C8.5 29.6467 8.5 30.2067 8.71799 30.6345C8.90973 31.0109 9.21569 31.3168 9.59202 31.5086C10.0198 31.7266 10.5799 31.7266 11.7 31.7266H12" stroke="white" stroke-linecap="round"/>
<path d="M16.3253 15.4993V24.2266H14.7443V17.0376H14.6932L12.652 18.3416V16.8928L14.821 15.4993H16.3253ZM19.5085 23.1783C19.25 23.1783 19.0284 23.0874 18.8438 22.9055C18.6591 22.7209 18.5682 22.4993 18.571 22.2408C18.5682 21.9851 18.6591 21.7663 18.8438 21.5845C19.0284 21.4027 19.25 21.3118 19.5085 21.3118C19.7585 21.3118 19.9759 21.4027 20.1605 21.5845C20.348 21.7663 20.4432 21.9851 20.446 22.2408C20.4432 22.4141 20.3977 22.5717 20.3097 22.7138C20.2244 22.8558 20.1108 22.9695 19.9688 23.0547C19.8295 23.1371 19.6761 23.1783 19.5085 23.1783ZM19.5085 18.853C19.25 18.853 19.0284 18.7621 18.8438 18.5803C18.6591 18.3956 18.5682 18.174 18.571 17.9155C18.5682 17.6598 18.6591 17.4411 18.8438 17.2592C19.0284 17.0746 19.25 16.9822 19.5085 16.9822C19.7585 16.9822 19.9759 17.0746 20.1605 17.2592C20.348 17.4411 20.4432 17.6598 20.446 17.9155C20.4432 18.0859 20.3977 18.2422 20.3097 18.3842C20.2244 18.5263 20.1108 18.6399 19.9688 18.7251C19.8295 18.8104 19.6761 18.853 19.5085 18.853ZM25.5714 15.4993V24.2266H23.9904V17.0376H23.9393L21.8981 18.3416V16.8928L24.0671 15.4993H25.5714Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_26160_90104">
<rect width="24" height="24" fill="white" transform="translate(8 8.22656)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@@ -0,0 +1,14 @@
<svg width="40" height="41" viewBox="0 0 40 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_26160_90134)">
<path d="M8.5 12.2266V11.9266C8.5 10.8065 8.5 10.2464 8.71799 9.81858C8.90973 9.44226 9.21569 9.1363 9.59202 8.94455C10.0198 8.72656 10.5799 8.72656 11.7 8.72656H12" stroke="white" stroke-linecap="round"/>
<path d="M28 8.72656H28.3C29.4201 8.72656 29.9802 8.72656 30.408 8.94455C30.7843 9.1363 31.0903 9.44226 31.282 9.81858C31.5 10.2464 31.5 10.8065 31.5 11.9266V12.2266" stroke="white" stroke-linecap="round"/>
<path d="M31.5 28.2266V28.5266C31.5 29.6467 31.5 30.2067 31.282 30.6345C31.0903 31.0109 30.7843 31.3168 30.408 31.5086C29.9802 31.7266 29.4201 31.7266 28.3 31.7266H28" stroke="white" stroke-linecap="round"/>
<path d="M8.5 28.2266V28.5266C8.5 29.6467 8.5 30.2067 8.71799 30.6345C8.90973 31.0109 9.21569 31.3168 9.59202 31.5086C10.0198 31.7266 10.5799 31.7266 11.7 31.7266H12" stroke="white" stroke-linecap="round"/>
<path d="M13.9077 25.1193C13.294 25.1193 12.7486 25.0142 12.2713 24.804C11.7969 24.5937 11.4219 24.3011 11.1463 23.9261C10.8707 23.5511 10.7244 23.1179 10.7074 22.6264H12.3097C12.3239 22.8622 12.402 23.0682 12.544 23.2443C12.6861 23.4176 12.875 23.5526 13.1108 23.6491C13.3466 23.7457 13.6108 23.794 13.9034 23.794C14.2159 23.794 14.4929 23.7401 14.7344 23.6321C14.9759 23.5213 15.1648 23.3679 15.3011 23.1719C15.4375 22.9759 15.5043 22.75 15.5014 22.4943C15.5043 22.2301 15.4361 21.9972 15.2969 21.7955C15.1577 21.5937 14.956 21.4361 14.6918 21.3224C14.4304 21.2088 14.1151 21.152 13.7457 21.152H12.9744V19.9332H13.7457C14.0497 19.9332 14.3153 19.8807 14.5426 19.7756C14.7727 19.6705 14.9531 19.5227 15.0838 19.3324C15.2145 19.1392 15.2784 18.9162 15.2756 18.6634C15.2784 18.4162 15.223 18.2017 15.1094 18.0199C14.9986 17.8352 14.8409 17.6918 14.6364 17.5895C14.4347 17.4872 14.1974 17.4361 13.9247 17.4361C13.6577 17.4361 13.4105 17.4844 13.1832 17.581C12.956 17.6776 12.7727 17.8153 12.6335 17.9943C12.4943 18.1705 12.4205 18.3807 12.4119 18.625H10.8906C10.902 18.1364 11.0426 17.7074 11.3125 17.3381C11.5852 16.9659 11.9489 16.6761 12.4034 16.4688C12.858 16.2585 13.3679 16.1534 13.9332 16.1534C14.5156 16.1534 15.0213 16.2628 15.4503 16.4815C15.8821 16.6974 16.2159 16.9886 16.4517 17.3551C16.6875 17.7216 16.8054 18.1264 16.8054 18.5696C16.8082 19.0611 16.6634 19.473 16.3707 19.8054C16.081 20.1378 15.7003 20.3551 15.2287 20.4574V20.5256C15.8423 20.6108 16.3125 20.8381 16.6392 21.2074C16.9688 21.5739 17.1321 22.0298 17.1293 22.5753C17.1293 23.0639 16.9901 23.5014 16.7116 23.8878C16.4361 24.2713 16.0554 24.5724 15.5696 24.7912C15.0866 25.0099 14.5327 25.1193 13.9077 25.1193ZM19.5593 23.9517C19.3008 23.9517 19.0792 23.8608 18.8945 23.679C18.7099 23.4943 18.619 23.2727 18.6218 23.0142C18.619 22.7585 18.7099 22.5398 18.8945 22.358C19.0792 22.1761 19.3008 22.0852 19.5593 22.0852C19.8093 22.0852 20.0266 22.1761 20.2113 22.358C20.3988 22.5398 20.494 22.7585 20.4968 23.0142C20.494 23.1875 20.4485 23.3452 20.3604 23.4872C20.2752 23.6293 20.1616 23.7429 20.0195 23.8281C19.8803 23.9105 19.7269 23.9517 19.5593 23.9517ZM19.5593 19.6264C19.3008 19.6264 19.0792 19.5355 18.8945 19.3537C18.7099 19.169 18.619 18.9474 18.6218 18.6889C18.619 18.4332 18.7099 18.2145 18.8945 18.0327C19.0792 17.848 19.3008 17.7557 19.5593 17.7557C19.8093 17.7557 20.0266 17.848 20.2113 18.0327C20.3988 18.2145 20.494 18.4332 20.4968 18.6889C20.494 18.8594 20.4485 19.0156 20.3604 19.1577C20.2752 19.2997 20.1616 19.4134 20.0195 19.4986C19.8803 19.5838 19.7269 19.6264 19.5593 19.6264ZM21.9148 23.3807V22.1236L25.6179 16.2727H26.6662V18.0625H26.027L23.5341 22.0128V22.081H28.7031V23.3807H21.9148ZM26.0781 25V22.9972L26.0952 22.4347V16.2727H27.5866V25H26.0781Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_26160_90134">
<rect width="24" height="24" fill="white" transform="translate(8 8.22656)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@@ -0,0 +1,14 @@
<svg width="40" height="41" viewBox="0 0 40 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_26160_90142)">
<path d="M8.5 12.2266V11.9266C8.5 10.8065 8.5 10.2464 8.71799 9.81858C8.90973 9.44226 9.21569 9.1363 9.59202 8.94455C10.0198 8.72656 10.5799 8.72656 11.7 8.72656H12" stroke="white" stroke-linecap="round"/>
<path d="M28 8.72656H28.3C29.4201 8.72656 29.9802 8.72656 30.408 8.94455C30.7843 9.1363 31.0903 9.44226 31.282 9.81858C31.5 10.2464 31.5 10.8065 31.5 11.9266V12.2266" stroke="white" stroke-linecap="round"/>
<path d="M31.5 28.2266V28.5266C31.5 29.6467 31.5 30.2067 31.282 30.6345C31.0903 31.0109 30.7843 31.3168 30.408 31.5086C29.9802 31.7266 29.4201 31.7266 28.3 31.7266H28" stroke="white" stroke-linecap="round"/>
<path d="M8.5 28.2266V28.5266C8.5 29.6467 8.5 30.2067 8.71799 30.6345C8.90973 31.0109 9.21569 31.3168 9.59202 31.5086C10.0198 31.7266 10.5799 31.7266 11.7 31.7266H12" stroke="white" stroke-linecap="round"/>
<path d="M10.6179 23.3807V22.1236L14.321 16.2727H15.3693V18.0625H14.7301L12.2372 22.0128V22.081H17.4062V23.3807H10.6179ZM14.7812 25V22.9972L14.7983 22.4347V16.2727H16.2898V25H14.7812ZM19.7351 23.9517C19.4766 23.9517 19.255 23.8608 19.0703 23.679C18.8857 23.4943 18.7947 23.2727 18.7976 23.0142C18.7947 22.7585 18.8857 22.5398 19.0703 22.358C19.255 22.1761 19.4766 22.0852 19.7351 22.0852C19.9851 22.0852 20.2024 22.1761 20.3871 22.358C20.5746 22.5398 20.6697 22.7585 20.6726 23.0142C20.6697 23.1875 20.6243 23.3452 20.5362 23.4872C20.451 23.6293 20.3374 23.7429 20.1953 23.8281C20.0561 23.9105 19.9027 23.9517 19.7351 23.9517ZM19.7351 19.6264C19.4766 19.6264 19.255 19.5355 19.0703 19.3537C18.8857 19.169 18.7947 18.9474 18.7976 18.6889C18.7947 18.4332 18.8857 18.2145 19.0703 18.0327C19.255 17.848 19.4766 17.7557 19.7351 17.7557C19.9851 17.7557 20.2024 17.848 20.3871 18.0327C20.5746 18.2145 20.6697 18.4332 20.6726 18.6889C20.6697 18.8594 20.6243 19.0156 20.5362 19.1577C20.451 19.2997 20.3374 19.4134 20.1953 19.4986C20.0561 19.5838 19.9027 19.6264 19.7351 19.6264ZM25.3803 25.1193C24.7667 25.1193 24.2212 25.0142 23.744 24.804C23.2695 24.5937 22.8945 24.3011 22.619 23.9261C22.3434 23.5511 22.1971 23.1179 22.18 22.6264H23.7823C23.7965 22.8622 23.8746 23.0682 24.0167 23.2443C24.1587 23.4176 24.3477 23.5526 24.5835 23.6491C24.8192 23.7457 25.0835 23.794 25.3761 23.794C25.6886 23.794 25.9656 23.7401 26.207 23.6321C26.4485 23.5213 26.6374 23.3679 26.7738 23.1719C26.9102 22.9759 26.9769 22.75 26.9741 22.4943C26.9769 22.2301 26.9087 21.9972 26.7695 21.7955C26.6303 21.5937 26.4286 21.4361 26.1644 21.3224C25.9031 21.2088 25.5877 21.152 25.2184 21.152H24.4471V19.9332H25.2184C25.5224 19.9332 25.788 19.8807 26.0153 19.7756C26.2454 19.6705 26.4258 19.5227 26.5565 19.3324C26.6871 19.1392 26.7511 18.9162 26.7482 18.6634C26.7511 18.4162 26.6957 18.2017 26.582 18.0199C26.4712 17.8352 26.3136 17.6918 26.109 17.5895C25.9073 17.4872 25.6701 17.4361 25.3974 17.4361C25.1303 17.4361 24.8832 17.4844 24.6559 17.581C24.4286 17.6776 24.2454 17.8153 24.1062 17.9943C23.967 18.1705 23.8931 18.3807 23.8846 18.625H22.3633C22.3746 18.1364 22.5153 17.7074 22.7852 17.3381C23.0579 16.9659 23.4215 16.6761 23.8761 16.4688C24.3306 16.2585 24.8406 16.1534 25.4059 16.1534C25.9883 16.1534 26.494 16.2628 26.9229 16.4815C27.3548 16.6974 27.6886 16.9886 27.9244 17.3551C28.1602 17.7216 28.2781 18.1264 28.2781 18.5696C28.2809 19.0611 28.136 19.473 27.8434 19.8054C27.5536 20.1378 27.1729 20.3551 26.7013 20.4574V20.5256C27.315 20.6108 27.7852 20.8381 28.1119 21.2074C28.4414 21.5739 28.6048 22.0298 28.6019 22.5753C28.6019 23.0639 28.4627 23.5014 28.1843 23.8878C27.9087 24.2713 27.5281 24.5724 27.0423 24.7912C26.5593 25.0099 26.0053 25.1193 25.3803 25.1193Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_26160_90142">
<rect width="24" height="24" fill="white" transform="translate(8 8.22656)"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@@ -0,0 +1,7 @@
<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M30 6.5L30.3 6.5C31.4201 6.5 31.9802 6.5 32.408 6.71799C32.7843 6.90973 33.0903 7.21569 33.282 7.59202C33.5 8.01984 33.5 8.57989 33.5 9.7L33.5 10" stroke="white" stroke-linecap="round"/>
<path d="M33.5 31L33.5 31.3C33.5 32.4201 33.5 32.9802 33.282 33.408C33.0903 33.7843 32.7843 34.0903 32.408 34.282C31.9802 34.5 31.4201 34.5 30.3 34.5L30 34.5" stroke="white" stroke-linecap="round"/>
<path d="M11 34.5L10.7 34.5C9.57989 34.5 9.01984 34.5 8.59202 34.282C8.21569 34.0903 7.90973 33.7843 7.71799 33.408C7.5 32.9802 7.5 32.4201 7.5 31.3L7.5 31" stroke="white" stroke-linecap="round"/>
<path d="M11 6.5L10.7 6.5C9.57989 6.5 9.01984 6.5 8.59202 6.71799C8.21569 6.90973 7.90973 7.21569 7.71799 7.59202C7.5 8.01984 7.5 8.57989 7.5 9.7L7.5 10" stroke="white" stroke-linecap="round"/>
<path d="M11.8054 16.1534C12.223 16.1562 12.6293 16.2301 13.0241 16.375C13.4219 16.517 13.7798 16.75 14.098 17.0739C14.4162 17.3949 14.669 17.8253 14.8565 18.3651C15.044 18.9048 15.1378 19.5724 15.1378 20.3679C15.1406 21.1179 15.0611 21.7884 14.8991 22.3793C14.7401 22.9673 14.5114 23.4645 14.2131 23.8707C13.9148 24.277 13.5554 24.5866 13.1349 24.7997C12.7145 25.0128 12.2415 25.1193 11.7159 25.1193C11.1648 25.1193 10.6761 25.0114 10.25 24.7955C9.8267 24.5795 9.48438 24.2841 9.22301 23.9091C8.96165 23.5341 8.80114 23.1051 8.74148 22.6222H10.2969C10.3764 22.9687 10.5384 23.2443 10.7827 23.4489C11.0298 23.6506 11.3409 23.7514 11.7159 23.7514C12.321 23.7514 12.7869 23.4886 13.1136 22.9631C13.4403 22.4375 13.6037 21.7074 13.6037 20.7727H13.544C13.4048 21.0227 13.2244 21.2386 13.0028 21.4205C12.7813 21.5994 12.5298 21.7372 12.2486 21.8338C11.9702 21.9304 11.6747 21.9787 11.3622 21.9787C10.8509 21.9787 10.3906 21.8565 9.98153 21.6122C9.57528 21.3679 9.25284 21.0327 9.0142 20.6065C8.77841 20.1804 8.65909 19.6932 8.65625 19.1449C8.65625 18.5767 8.78693 18.0668 9.0483 17.6151C9.3125 17.1605 9.6804 16.8026 10.152 16.5412C10.6236 16.277 11.1747 16.1477 11.8054 16.1534ZM11.8097 17.4318C11.5028 17.4318 11.2259 17.5071 10.9787 17.6577C10.7344 17.8054 10.5412 18.0071 10.3991 18.2628C10.2599 18.5156 10.1903 18.7983 10.1903 19.1108C10.1932 19.4205 10.2628 19.7017 10.3991 19.9545C10.5384 20.2074 10.7273 20.4077 10.9659 20.5554C11.2074 20.7031 11.483 20.777 11.7926 20.777C12.0227 20.777 12.2372 20.733 12.4361 20.6449C12.6349 20.5568 12.8082 20.4347 12.956 20.2784C13.1065 20.1193 13.223 19.9389 13.3054 19.7372C13.3906 19.5355 13.4318 19.3224 13.429 19.098C13.429 18.7997 13.358 18.5241 13.2159 18.2713C13.0767 18.0185 12.8849 17.8153 12.6406 17.6619C12.3991 17.5085 12.1222 17.4318 11.8097 17.4318ZM17.5241 23.9517C17.2656 23.9517 17.044 23.8608 16.8594 23.679C16.6747 23.4943 16.5838 23.2727 16.5866 23.0142C16.5838 22.7585 16.6747 22.5398 16.8594 22.358C17.044 22.1761 17.2656 22.0852 17.5241 22.0852C17.7741 22.0852 17.9915 22.1761 18.1761 22.358C18.3636 22.5398 18.4588 22.7585 18.4616 23.0142C18.4588 23.1875 18.4134 23.3452 18.3253 23.4872C18.2401 23.6293 18.1264 23.7429 17.9844 23.8281C17.8452 23.9105 17.6918 23.9517 17.5241 23.9517ZM17.5241 19.6264C17.2656 19.6264 17.044 19.5355 16.8594 19.3537C16.6747 19.169 16.5838 18.9474 16.5866 18.6889C16.5838 18.4332 16.6747 18.2145 16.8594 18.0327C17.044 17.848 17.2656 17.7557 17.5241 17.7557C17.7741 17.7557 17.9915 17.848 18.1761 18.0327C18.3636 18.2145 18.4588 18.4332 18.4616 18.6889C18.4588 18.8594 18.4134 19.0156 18.3253 19.1577C18.2401 19.2997 18.1264 19.4134 17.9844 19.4986C17.8452 19.5838 17.6918 19.6264 17.5241 19.6264ZM23.587 16.2727V25H22.006V17.8111H21.9549L19.9137 19.1151V17.6662L22.0827 16.2727H23.587ZM28.9989 25.1193C28.5813 25.1165 28.1737 25.044 27.7759 24.902C27.3782 24.7571 27.0202 24.5227 26.7021 24.1989C26.3839 23.8722 26.131 23.4389 25.9435 22.8991C25.756 22.3565 25.6637 21.6847 25.6665 20.8835C25.6665 20.1364 25.7461 19.4702 25.9052 18.8849C26.0643 18.2997 26.293 17.8054 26.5913 17.402C26.8896 16.9957 27.2489 16.6861 27.6694 16.473C28.0927 16.2599 28.5657 16.1534 29.0884 16.1534C29.6367 16.1534 30.1225 16.2614 30.5458 16.4773C30.9719 16.6932 31.3157 16.9886 31.5771 17.3636C31.8384 17.7358 32.0004 18.1562 32.0629 18.625H30.5075C30.4279 18.2898 30.2646 18.0227 30.0174 17.8239C29.7731 17.6222 29.4634 17.5213 29.0884 17.5213C28.4833 17.5213 28.0174 17.7841 27.6907 18.3097C27.3668 18.8352 27.2035 19.5568 27.2006 20.4744H27.2603C27.3995 20.2244 27.5799 20.0099 27.8015 19.831C28.0231 19.652 28.2731 19.5142 28.5515 19.4176C28.8327 19.3182 29.1296 19.2685 29.4421 19.2685C29.9535 19.2685 30.4123 19.3906 30.8185 19.6349C31.2276 19.8793 31.5515 20.2159 31.7901 20.6449C32.0288 21.071 32.1467 21.5597 32.1438 22.1108C32.1467 22.6847 32.016 23.2003 31.7518 23.6577C31.4876 24.1122 31.1197 24.4702 30.6481 24.7315C30.1765 24.9929 29.6268 25.1222 28.9989 25.1193ZM28.9904 23.8409C29.3001 23.8409 29.5771 23.7656 29.8214 23.6151C30.0657 23.4645 30.2589 23.2614 30.4009 23.0057C30.543 22.75 30.6126 22.4631 30.6097 22.1449C30.6126 21.8324 30.5444 21.5497 30.4052 21.2969C30.2688 21.044 30.0799 20.8437 29.8384 20.696C29.5969 20.5483 29.3214 20.4744 29.0117 20.4744C28.7816 20.4744 28.5671 20.5185 28.3683 20.6065C28.1694 20.6946 27.9961 20.8168 27.8484 20.973C27.7006 21.1264 27.5842 21.3054 27.4989 21.5099C27.4165 21.7116 27.3739 21.9276 27.3711 22.1577C27.3739 22.4616 27.445 22.7415 27.5842 22.9972C27.7234 23.2528 27.9151 23.4574 28.1594 23.6108C28.4038 23.7642 28.6808 23.8409 28.9904 23.8409Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 5.4 KiB

View File

@@ -0,0 +1,4 @@
<svg width="41" height="41" viewBox="0 0 41 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M14.5 10.2266V24.2266C14.5 24.757 14.7107 25.2657 15.0858 25.6408C15.4609 26.0158 15.9696 26.2266 16.5 26.2266H30.5" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M26.5 30.2266V16.2266C26.5 15.6961 26.2893 15.1874 25.9142 14.8123C25.5391 14.4373 25.0304 14.2266 24.5 14.2266H10.5" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
</svg>

After

Width:  |  Height:  |  Size: 518 B

View File

@@ -0,0 +1,3 @@
<svg width="41" height="41" viewBox="0 0 41 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M17.5 9.22656H11.5C10.9696 9.22656 10.4609 9.43728 10.0858 9.81235C9.71071 10.1874 9.5 10.6961 9.5 11.2266V24.2266C9.5 24.757 9.71071 25.2657 10.0858 25.6408C10.4609 26.0158 10.9696 26.2266 11.5 26.2266H12.5V23.2266H11.5V11.2266H17.5V19.2266H19.5V11.2266C19.5 10.6961 19.2893 10.1874 18.9142 9.81235C18.5391 9.43728 18.0304 9.22656 17.5 9.22656ZM31.5 29.2266V23.2266C31.5 22.6961 31.2893 22.1874 30.9142 21.8123C30.5391 21.4373 30.0304 21.2266 29.5 21.2266H16.5C15.9696 21.2266 15.4609 21.4373 15.0858 21.8123C14.7107 22.1874 14.5 22.6961 14.5 23.2266V29.2266C14.5 29.757 14.7107 30.2657 15.0858 30.6408C15.4609 31.0158 15.9696 31.2266 16.5 31.2266H29.5C30.0304 31.2266 30.5391 31.0158 30.9142 30.6408C31.2893 30.2657 31.5 29.757 31.5 29.2266ZM17.5 29.2266V23.2266H29.5V29.2266H17.5ZM31.5 18.2266H30C30 15.2266 28.19 12.4966 25.42 11.3166L24.5 13.2266L22.5 9.22656C24.8869 9.22656 27.1761 10.1748 28.864 11.8626C30.5518 13.5504 31.5 15.8396 31.5 18.2266Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -0,0 +1,3 @@
<svg width="41" height="41" viewBox="0 0 41 41" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M27.8816 28.7689L20.5736 21.4609L17.4536 24.5799C17.6003 24.8299 17.7083 25.0932 17.7776 25.3699C17.847 25.6465 17.8816 25.9332 17.8816 26.2299C17.8816 27.1399 17.558 27.9185 16.9106 28.5659C16.2633 29.2139 15.485 29.5379 14.5756 29.5379C13.6663 29.5379 12.8873 29.2142 12.2386 28.5669C11.59 27.9195 11.2656 27.1412 11.2656 26.2319C11.2656 25.3225 11.5896 24.5439 12.2376 23.8959C12.8856 23.2465 13.6643 22.9219 14.5736 22.9219C14.8696 22.9219 15.1563 22.9565 15.4336 23.0259C15.7103 23.0952 15.9736 23.2029 16.2236 23.3489L19.3436 20.2299L16.2236 17.1099C15.9736 17.2565 15.7103 17.3645 15.4336 17.4339C15.157 17.5032 14.8703 17.5379 14.5736 17.5379C13.6643 17.5379 12.8856 17.2142 12.2376 16.5669C11.5896 15.9195 11.2656 15.1412 11.2656 14.2319C11.2656 13.3225 11.5893 12.5439 12.2366 11.8959C12.884 11.2465 13.6623 10.9219 14.5716 10.9219C15.481 10.9219 16.2596 11.2459 16.9076 11.8939C17.557 12.5419 17.8816 13.3205 17.8816 14.2299C17.8816 14.5259 17.847 14.8125 17.7776 15.0899C17.7083 15.3665 17.6006 15.6299 17.4546 15.8799L29.7266 28.1529V28.7689H27.8816ZM23.1116 18.9219L21.8816 17.6919L27.8816 11.6919H29.7276V12.3069L23.1116 18.9219ZM14.5746 16.5379C15.2093 16.5379 15.7526 16.3119 16.2046 15.8599C16.6566 15.4079 16.882 14.8645 16.8806 14.2299C16.8793 13.5952 16.6536 13.0519 16.2036 12.5999C15.7536 12.1479 15.2103 11.9219 14.5736 11.9219C13.937 11.9219 13.3936 12.1479 12.9436 12.5999C12.4936 13.0519 12.2676 13.5952 12.2656 14.2299C12.2636 14.8645 12.4896 15.4079 12.9436 15.8599C13.3976 16.3119 13.942 16.5379 14.5746 16.5379ZM14.5736 28.5379C15.2083 28.5379 15.7516 28.3119 16.2036 27.8599C16.6556 27.4079 16.8813 26.8645 16.8806 26.2299C16.88 25.5952 16.6543 25.0519 16.2036 24.5999C15.753 24.1479 15.2096 23.9219 14.5736 23.9219C13.9376 23.9219 13.3943 24.1479 12.9436 24.5999C12.493 25.0519 12.267 25.5952 12.2656 26.2299C12.2643 26.8645 12.4903 27.4079 12.9436 27.8599C13.397 28.3119 13.9403 28.5379 14.5736 28.5379Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -220,6 +220,8 @@ TextTheme _buildTextTheme(Color textColor) {
}
extension CustomColorScheme on ColorScheme {
Color get videoPlayerPrimaryColor => const Color.fromRGBO(1, 222, 77, 1);
Color get defaultBackgroundColor =>
brightness == Brightness.light ? backgroundBaseLight : backgroundBaseDark;
@@ -392,7 +394,9 @@ ElevatedButtonThemeData buildElevatedButtonThemeData({
}) {
return ElevatedButtonThemeData(
style: ElevatedButton.styleFrom(
foregroundColor: onPrimary, backgroundColor: primary, elevation: elevation,
foregroundColor: onPrimary,
backgroundColor: primary,
elevation: elevation,
alignment: Alignment.center,
textStyle: const TextStyle(
fontWeight: FontWeight.w600,

View File

@@ -1193,6 +1193,7 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage(
"Save your recovery key if you haven\'t already"),
"saving": MessageLookupByLibrary.simpleMessage("Saving..."),
"savingEdits": MessageLookupByLibrary.simpleMessage("Saving Edits!"),
"scanCode": MessageLookupByLibrary.simpleMessage("Scan code"),
"scanThisBarcodeWithnyourAuthenticatorApp":
MessageLookupByLibrary.simpleMessage(

View File

@@ -587,7 +587,7 @@ class MessageLookup extends MessageLookupByLibrary {
"descriptions": MessageLookupByLibrary.simpleMessage("Descrições"),
"deselectAll": MessageLookupByLibrary.simpleMessage("Desmarcar todos"),
"designedToOutlive":
MessageLookupByLibrary.simpleMessage("Feito para ter logenvidade"),
MessageLookupByLibrary.simpleMessage("Feito para ter longevidade"),
"details": MessageLookupByLibrary.simpleMessage("Detalhes"),
"devAccountChanged": MessageLookupByLibrary.simpleMessage(
"A conta de desenvolvedor que usamos para publicar o Ente na App Store foi alterada. Por esse motivo, você precisará fazer entrar novamente.\n\nPedimos desculpas pelo inconveniente, mas isso era inevitável."),

View File

@@ -543,7 +543,7 @@ class MessageLookup extends MessageLookupByLibrary {
"emailVerificationToggle":
MessageLookupByLibrary.simpleMessage("电子邮件验证"),
"emailYourLogs": MessageLookupByLibrary.simpleMessage("通过电子邮件发送您的日志"),
"empty": MessageLookupByLibrary.simpleMessage(""),
"empty": MessageLookupByLibrary.simpleMessage(""),
"emptyTrash": MessageLookupByLibrary.simpleMessage("要清空回收站吗?"),
"enableMaps": MessageLookupByLibrary.simpleMessage("启用地图"),
"enableMapsDesc": MessageLookupByLibrary.simpleMessage(

View File

@@ -8703,6 +8703,16 @@ class S {
args: [],
);
}
/// `Saving Edits!`
String get savingEdits {
return Intl.message(
'Saving Edits!',
name: 'savingEdits',
desc: '',
args: [],
);
}
}
class AppLocalizationDelegate extends LocalizationsDelegate<S> {

View File

@@ -1226,5 +1226,6 @@
"stopCastingBody": "Do you want to stop casting?",
"castIPMismatchTitle": "Failed to cast album",
"castIPMismatchBody": "Please make sure you are on the same network as the TV.",
"pairingComplete": "Pairing complete"
"pairingComplete": "Pairing complete",
"savingEdits": "Saving Edits!"
}

View File

@@ -1,177 +0,0 @@
import 'package:flutter/material.dart';
import 'package:fraction/fraction.dart';
import 'package:video_editor/video_editor.dart';
class CropPage extends StatelessWidget {
const CropPage({super.key, required this.controller});
final VideoEditorController controller;
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.black,
body: SafeArea(
child: Padding(
padding: const EdgeInsets.symmetric(vertical: 30),
child: Column(
children: [
Row(
children: [
Expanded(
child: IconButton(
onPressed: () =>
controller.rotate90Degrees(RotateDirection.left),
icon: const Icon(Icons.rotate_left),
),
),
Expanded(
child: IconButton(
onPressed: () =>
controller.rotate90Degrees(RotateDirection.right),
icon: const Icon(Icons.rotate_right),
),
),
],
),
const SizedBox(height: 15),
Expanded(
child: CropGridViewer.edit(
controller: controller,
rotateCropArea: false,
margin: const EdgeInsets.symmetric(horizontal: 20),
),
),
const SizedBox(height: 15),
Row(
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Expanded(
flex: 2,
child: IconButton(
onPressed: () => Navigator.pop(context),
icon: const Center(
child: Text(
"cancel",
style: TextStyle(fontWeight: FontWeight.bold),
),
),
),
),
Expanded(
flex: 4,
child: AnimatedBuilder(
animation: controller,
builder: (_, __) => Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
IconButton(
onPressed: () =>
controller.preferredCropAspectRatio =
controller.preferredCropAspectRatio
?.toFraction()
.inverse()
.toDouble(),
icon: controller.preferredCropAspectRatio !=
null &&
controller.preferredCropAspectRatio! < 1
? const Icon(
Icons.panorama_vertical_select_rounded,
)
: const Icon(
Icons.panorama_vertical_rounded,
),
),
IconButton(
onPressed: () =>
controller.preferredCropAspectRatio =
controller.preferredCropAspectRatio
?.toFraction()
.inverse()
.toDouble(),
icon: controller.preferredCropAspectRatio !=
null &&
controller.preferredCropAspectRatio! > 1
? const Icon(
Icons
.panorama_horizontal_select_rounded,
)
: const Icon(
Icons.panorama_horizontal_rounded,
),
),
],
),
Row(
children: [
_buildCropButton(context, null),
_buildCropButton(context, 1.toFraction()),
_buildCropButton(
context,
Fraction.fromString("9/16"),
),
_buildCropButton(
context,
Fraction.fromString("3/4"),
),
],
),
],
),
),
),
Expanded(
flex: 2,
child: IconButton(
onPressed: () {
// WAY 1: validate crop parameters set in the crop view
controller.applyCacheCrop();
// WAY 2: update manually with Offset values
// controller.updateCrop(const Offset(0.2, 0.2), const Offset(0.8, 0.8));
Navigator.pop(context);
},
icon: Center(
child: Text(
"done",
style: TextStyle(
color:
const CropGridStyle().selectedBoundariesColor,
fontWeight: FontWeight.bold,
),
),
),
),
),
],
),
],
),
),
),
);
}
Widget _buildCropButton(BuildContext context, Fraction? f) {
if (controller.preferredCropAspectRatio != null &&
controller.preferredCropAspectRatio! > 1) f = f?.inverse();
return Flexible(
child: TextButton(
style: ElevatedButton.styleFrom(
elevation: 0,
backgroundColor: controller.preferredCropAspectRatio == f?.toDouble()
? Colors.grey.shade800
: null,
foregroundColor: controller.preferredCropAspectRatio == f?.toDouble()
? Colors.white
: null,
textStyle: Theme.of(context).textTheme.bodySmall,
),
onPressed: () => controller.preferredCropAspectRatio = f?.toDouble(),
child: Text(f == null ? 'free' : '${f.numerator}:${f.denominator}'),
),
);
}
}

View File

@@ -0,0 +1,122 @@
import 'package:flutter/material.dart';
import "package:flutter_svg/flutter_svg.dart";
import "package:photos/ui/tools/editor/video_editor/crop_value.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_bottom_action.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_main_actions.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_navigation_options.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_player_control.dart";
import 'package:video_editor/video_editor.dart';
class VideoCropPage extends StatefulWidget {
const VideoCropPage({super.key, required this.controller});
final VideoEditorController controller;
@override
State<VideoCropPage> createState() => _VideoCropPageState();
}
class _VideoCropPageState extends State<VideoCropPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.black,
body: SafeArea(
child: Column(
children: [
Expanded(
child: Hero(
tag: "video-editor-preview",
child: CropGridViewer.edit(
controller: widget.controller,
rotateCropArea: false,
margin: const EdgeInsets.symmetric(horizontal: 20),
),
),
),
VideoEditorPlayerControl(
controller: widget.controller,
),
Row(
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Expanded(
flex: 4,
child: AnimatedBuilder(
animation: widget.controller,
builder: (_, __) => Column(
children: [
VideoEditorMainActions(
children: [
// _buildCropButton(context, CropValue.original),
// const SizedBox(width: 40),
_buildCropButton(context, CropValue.free),
const SizedBox(width: 40),
_buildCropButton(context, CropValue.ratio_1_1),
const SizedBox(width: 40),
_buildCropButton(
context,
CropValue.ratio_9_16,
),
const SizedBox(width: 40),
_buildCropButton(
context,
CropValue.ratio_16_9,
),
const SizedBox(width: 40),
_buildCropButton(
context,
CropValue.ratio_3_4,
),
const SizedBox(width: 40),
_buildCropButton(
context,
CropValue.ratio_4_3,
),
],
),
],
),
),
),
],
),
const SizedBox(height: 40),
VideoEditorNavigationOptions(
secondaryText: "Done",
onSecondaryPressed: () {
// WAY 1: validate crop parameters set in the crop view
widget.controller.applyCacheCrop();
// WAY 2: update manually with Offset values
// controller.updateCrop(const Offset(0.2, 0.2), const Offset(0.8, 0.8));
Navigator.pop(context);
},
),
],
),
),
);
}
Widget _buildCropButton(BuildContext context, CropValue value) {
final f = value.getFraction();
return VideoEditorBottomAction(
label: value.displayName,
isSelected: value != CropValue.original &&
widget.controller.preferredCropAspectRatio == f?.toDouble(),
onPressed: () {
if (value == CropValue.original) {
widget.controller.updateCrop(Offset.zero, const Offset(1.0, 1.0));
widget.controller.cropAspectRatio(null);
setState(() {});
} else {
widget.controller.preferredCropAspectRatio = f?.toDouble();
}
},
child: SvgPicture.asset(
"assets/video-editor/video-crop-${value.name}-action.svg",
),
);
}
}

View File

@@ -0,0 +1,51 @@
import "package:fraction/fraction.dart";
enum CropValue {
original,
free,
ratio_1_1,
ratio_9_16,
ratio_16_9,
ratio_3_4,
ratio_4_3;
getFraction() {
switch (this) {
case CropValue.original:
return null;
case CropValue.free:
return null;
case CropValue.ratio_1_1:
return 1.toFraction();
case CropValue.ratio_9_16:
return Fraction.fromString("9/16");
case CropValue.ratio_16_9:
return Fraction.fromString("16/9");
case CropValue.ratio_3_4:
return Fraction.fromString("3/4");
case CropValue.ratio_4_3:
return Fraction.fromString("4/3");
default:
return null;
}
}
String get displayName {
switch (this) {
case CropValue.original:
return "Original";
case CropValue.free:
return "Free";
case CropValue.ratio_1_1:
return "1:1";
case CropValue.ratio_9_16:
return "9:16";
case CropValue.ratio_16_9:
return "16:9";
case CropValue.ratio_3_4:
return "3:4";
case CropValue.ratio_4_3:
return "4:3";
}
}
}

View File

@@ -0,0 +1,57 @@
import "package:flutter/material.dart";
class VideoEditorBottomAction extends StatelessWidget {
const VideoEditorBottomAction({
super.key,
required this.label,
this.icon,
this.child,
required this.onPressed,
this.isSelected = false,
}) : assert(icon != null || child != null);
final String label;
final IconData? icon;
final Widget? child;
final VoidCallback onPressed;
final bool isSelected;
@override
Widget build(BuildContext context) {
return GestureDetector(
onTap: onPressed,
behavior: HitTestBehavior.translucent,
child: Column(
children: [
Container(
height: 48,
width: 48,
decoration: BoxDecoration(
color: const Color(0xFF252525),
shape: BoxShape.circle,
border: Border.all(
color:
isSelected ? const Color(0xFFFFFFFF) : Colors.transparent,
width: 1,
),
),
child: icon != null
? Icon(icon!)
: Padding(
padding: const EdgeInsets.all(2),
child: child!,
),
),
const SizedBox(height: 8),
Text(
label,
style: const TextStyle(
fontSize: 12,
fontWeight: FontWeight.w600,
),
),
],
),
);
}
}

View File

@@ -0,0 +1,25 @@
import "package:flutter/material.dart";
class VideoEditorMainActions extends StatelessWidget {
const VideoEditorMainActions({
super.key,
required this.children,
});
final List<Widget> children;
@override
Widget build(BuildContext context) {
return Center(
child: SizedBox(
height: 76,
child: ListView(
padding: const EdgeInsets.symmetric(horizontal: 36),
scrollDirection: Axis.horizontal,
shrinkWrap: true,
children: children,
),
),
);
}
}

View File

@@ -0,0 +1,41 @@
import "package:flutter/material.dart";
class VideoEditorNavigationOptions extends StatelessWidget {
const VideoEditorNavigationOptions({
super.key,
this.primaryText,
this.onPrimaryPressed,
required this.secondaryText,
required this.onSecondaryPressed,
});
final String? primaryText;
final VoidCallback? onPrimaryPressed;
final String secondaryText;
final VoidCallback? onSecondaryPressed;
@override
Widget build(BuildContext context) {
return Hero(
tag: "video-editor-navigation-options",
child: Padding(
padding: const EdgeInsets.only(bottom: 12),
child: Row(
children: [
const SizedBox(width: 28),
TextButton(
onPressed: onPrimaryPressed?.call ?? Navigator.of(context).pop,
child: Text(primaryText ?? "Cancel"),
),
const Spacer(),
TextButton(
onPressed: onSecondaryPressed,
child: Text(secondaryText),
),
const SizedBox(width: 28),
],
),
),
);
}
}

View File

@@ -0,0 +1,77 @@
import "package:flutter/material.dart";
import "package:video_editor/video_editor.dart";
class VideoEditorPlayerControl extends StatelessWidget {
const VideoEditorPlayerControl({
super.key,
required this.controller,
});
final VideoEditorController controller;
@override
Widget build(BuildContext context) {
return Hero(
tag: "video_editor_player_control",
child: AnimatedBuilder(
animation: Listenable.merge([
controller,
controller.video,
]),
builder: (_, __) {
final duration = controller.trimmedDuration;
final pos = Duration(
seconds: (controller.videoPosition.inSeconds -
controller.startTrim.inSeconds),
);
final isPlaying = controller.isPlaying;
return GestureDetector(
onTap: () {
if (controller.isPlaying) {
controller.video.pause();
} else {
controller.video.play();
}
},
child: Container(
height: 28,
margin: const EdgeInsets.only(top: 24, bottom: 28),
padding: const EdgeInsets.symmetric(
horizontal: 10,
vertical: 4,
),
decoration: BoxDecoration(
color: const Color(0xFF252525),
borderRadius: BorderRadius.circular(56),
),
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Icon(
!isPlaying ? Icons.play_arrow : Icons.pause,
size: 21,
),
const SizedBox(width: 4),
Text(
"${formatter(pos)} / ${formatter(duration)}",
// ignore: prefer_const_constructors
style: TextStyle(
fontSize: 12,
fontWeight: FontWeight.w500,
),
),
],
),
),
);
},
),
);
}
String formatter(Duration duration) => [
duration.inMinutes.remainder(60).toString().padLeft(2, '0'),
duration.inSeconds.remainder(60).toString().padLeft(2, '0'),
].join(":");
}

View File

@@ -1,11 +1,31 @@
import 'dart:io';
import "dart:math";
import 'package:flutter/material.dart';
import "package:flutter_svg/flutter_svg.dart";
import "package:logging/logging.dart";
import 'package:path/path.dart' as path;
import "package:pedantic/pedantic.dart";
import "package:photo_manager/photo_manager.dart";
import "package:photos/core/event_bus.dart";
import "package:photos/db/files_db.dart";
import "package:photos/ente_theme_data.dart";
import "package:photos/events/local_photos_updated_event.dart";
import "package:photos/generated/l10n.dart";
import "package:photos/models/file/file.dart";
import 'package:photos/ui/tools/editor/crop_video_page.dart';
import 'package:photos/ui/tools/editor/export_video_result.dart';
import 'package:photos/ui/tools/editor/export_video_service.dart';
import "package:photos/services/sync_service.dart";
import "package:photos/ui/tools/editor/export_video_service.dart";
import 'package:photos/ui/tools/editor/video_crop_page.dart';
import "package:photos/ui/tools/editor/video_editor/video_editor_bottom_action.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_main_actions.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_navigation_options.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_player_control.dart";
import "package:photos/ui/tools/editor/video_rotate_page.dart";
import "package:photos/ui/tools/editor/video_trim_page.dart";
import "package:photos/ui/viewer/file/detail_page.dart";
import "package:photos/utils/dialog_util.dart";
import "package:photos/utils/navigation_util.dart";
import "package:photos/utils/toast_util.dart";
import "package:video_editor/video_editor.dart";
class VideoEditorPage extends StatefulWidget {
@@ -27,7 +47,7 @@ class VideoEditorPage extends StatefulWidget {
class _VideoEditorPageState extends State<VideoEditorPage> {
final _exportingProgress = ValueNotifier<double>(0.0);
final _isExporting = ValueNotifier<bool>(false);
final double height = 60;
final _logger = Logger("VideoEditor");
late final VideoEditorController _controller;
@@ -37,6 +57,10 @@ class _VideoEditorPageState extends State<VideoEditorPage> {
_controller = VideoEditorController.file(
widget.ioFile,
minDuration: const Duration(seconds: 1),
cropStyle: CropGridStyle(
selectedBoundariesColor:
const ColorScheme.dark().videoPlayerPrimaryColor,
),
);
_controller.initialize().then((_) => setState(() {})).catchError(
(error) {
@@ -56,21 +80,107 @@ class _VideoEditorPageState extends State<VideoEditorPage> {
super.dispose();
}
void _showErrorSnackBar(String message) =>
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text(message),
duration: const Duration(seconds: 1),
),
);
@override
Widget build(BuildContext context) {
return PopScope(
canPop: false,
child: Scaffold(
backgroundColor: Colors.black,
body: _controller.initialized
? SafeArea(
child: Stack(
children: [
Column(
children: [
Expanded(
child: Column(
children: [
Expanded(
child: Hero(
tag: "video-editor-preview",
child: CropGridViewer.preview(
controller: _controller,
),
),
),
VideoEditorPlayerControl(
controller: _controller,
),
VideoEditorMainActions(
children: [
VideoEditorBottomAction(
label: "Trim",
child: SvgPicture.asset(
"assets/video-editor/video-editor-trim-action.svg",
),
onPressed: () => Navigator.push(
context,
MaterialPageRoute<void>(
builder: (context) => VideoTrimPage(
controller: _controller,
),
),
),
),
const SizedBox(width: 40),
VideoEditorBottomAction(
label: "Crop",
child: SvgPicture.asset(
"assets/video-editor/video-editor-crop-action.svg",
),
onPressed: () => Navigator.push(
context,
MaterialPageRoute<void>(
builder: (context) => VideoCropPage(
controller: _controller,
),
),
),
),
const SizedBox(width: 40),
VideoEditorBottomAction(
label: "Rotate",
child: SvgPicture.asset(
"assets/video-editor/video-editor-rotate-action.svg",
),
onPressed: () => Navigator.push(
context,
MaterialPageRoute<void>(
builder: (context) => VideoRotatePage(
controller: _controller,
),
),
),
),
],
),
const SizedBox(height: 40),
VideoEditorNavigationOptions(
secondaryText: "Save copy",
onSecondaryPressed: () {
exportVideo();
},
),
],
),
),
],
),
],
),
)
: const Center(child: CircularProgressIndicator()),
),
);
}
void _exportVideo() async {
void exportVideo() async {
_exportingProgress.value = 0;
_isExporting.value = true;
final config = VideoFFmpegVideoEditorConfig(
_controller,
// format: VideoExportFormat.gif,
format: VideoExportFormat.mp4,
// commandBuilder: (config, videoPath, outputPath) {
// final List<String> filters = config.getExportFilters();
// filters.add('hflip'); // add horizontal flip
@@ -85,283 +195,60 @@ class _VideoEditorPageState extends State<VideoEditorPage> {
_exportingProgress.value =
config.getFFmpegProgress(stats.getTime().toInt());
},
onError: (e, s) => _showErrorSnackBar("Error on export video :("),
onCompleted: (file) {
onError: (e, s) => _logger.severe("Error exporting video", e, s),
onCompleted: (result) async {
_isExporting.value = false;
final dialog = createProgressDialog(context, S.of(context).savingEdits);
await dialog.show();
if (!mounted) return;
showDialog(
context: context,
builder: (_) => VideoResultPopup(video: file),
final fileName = path.basenameWithoutExtension(widget.file.title!) +
"_edited_" +
DateTime.now().microsecondsSinceEpoch.toString() +
".mp4";
//Disabling notifications for assets changing to insert the file into
//files db before triggering a sync.
await PhotoManager.stopChangeNotify();
final AssetEntity? newAsset =
await (PhotoManager.editor.saveVideo(result, title: fileName));
result.deleteSync();
final newFile = await EnteFile.fromAsset(
widget.file.deviceFolder ?? '',
newAsset!,
);
},
);
}
void _exportCover() async {
final config = CoverFFmpegVideoEditorConfig(_controller);
final execute = await config.getExecuteConfig();
if (execute == null) {
_showErrorSnackBar("Error on cover exportation initialization.");
return;
}
await ExportService.runFFmpegCommand(
execute,
onError: (e, s) => _showErrorSnackBar("Error on cover exportation :("),
onCompleted: (cover) {
if (!mounted) return;
showDialog(
context: context,
builder: (_) => CoverResultPopup(cover: cover),
newFile.generatedID = await FilesDB.instance.insert(widget.file);
Bus.instance
.fire(LocalPhotosUpdatedEvent([newFile], source: "editSave"));
unawaited(SyncService.instance.sync());
showShortToast(context, S.of(context).editsSaved);
_logger.info("Original file " + widget.file.toString());
_logger.info("Saved edits to file " + newFile.toString());
final existingFiles = widget.detailPageConfig.files;
final files = (await widget.detailPageConfig.asyncLoader!(
existingFiles[existingFiles.length - 1].creationTime!,
existingFiles[0].creationTime!,
))
.files;
// the index could be -1 if the files fetched doesn't contain the newly
// edited files
int selectionIndex =
files.indexWhere((file) => file.generatedID == newFile.generatedID);
if (selectionIndex == -1) {
files.add(newFile);
selectionIndex = files.length - 1;
}
replacePage(
context,
DetailPage(
widget.detailPageConfig.copyWith(
files: files,
selectedIndex: min(selectionIndex, files.length - 1),
),
),
);
await dialog.hide();
},
);
}
@override
Widget build(BuildContext context) {
return WillPopScope(
onWillPop: () async => false,
child: Scaffold(
backgroundColor: Colors.black,
body: _controller.initialized
? SafeArea(
child: Stack(
children: [
Column(
children: [
_topNavBar(),
Expanded(
child: DefaultTabController(
length: 2,
child: Column(
children: [
Expanded(
child: TabBarView(
physics:
const NeverScrollableScrollPhysics(),
children: [
Stack(
alignment: Alignment.center,
children: [
CropGridViewer.preview(
controller: _controller,
),
AnimatedBuilder(
animation: _controller.video,
builder: (_, __) => AnimatedOpacity(
opacity:
_controller.isPlaying ? 0 : 1,
duration: kThemeAnimationDuration,
child: GestureDetector(
onTap: _controller.video.play,
child: Container(
width: 40,
height: 40,
decoration:
const BoxDecoration(
color: Colors.white,
shape: BoxShape.circle,
),
child: const Icon(
Icons.play_arrow,
color: Colors.black,
),
),
),
),
),
],
),
CoverViewer(controller: _controller),
],
),
),
Container(
height: 200,
margin: const EdgeInsets.only(top: 10),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: _trimSlider(),
),
),
ValueListenableBuilder(
valueListenable: _isExporting,
builder: (_, bool export, Widget? child) =>
AnimatedSize(
duration: kThemeAnimationDuration,
child: export ? child : null,
),
child: AlertDialog(
title: ValueListenableBuilder(
valueListenable: _exportingProgress,
builder: (_, double value, __) => Text(
"Exporting video ${(value * 100).ceil()}%",
style: const TextStyle(fontSize: 12),
),
),
),
),
],
),
),
),
],
),
],
),
)
: const Center(child: CircularProgressIndicator()),
),
);
}
Widget _topNavBar() {
return SafeArea(
child: SizedBox(
height: height,
child: Row(
children: [
Expanded(
child: IconButton(
onPressed: () => Navigator.of(context).pop(),
icon: const Icon(Icons.exit_to_app),
tooltip: 'Leave editor',
),
),
const VerticalDivider(endIndent: 22, indent: 22),
Expanded(
child: IconButton(
onPressed: () =>
_controller.rotate90Degrees(RotateDirection.left),
icon: const Icon(Icons.rotate_left),
tooltip: 'Rotate unclockwise',
),
),
Expanded(
child: IconButton(
onPressed: () =>
_controller.rotate90Degrees(RotateDirection.right),
icon: const Icon(Icons.rotate_right),
tooltip: 'Rotate clockwise',
),
),
Expanded(
child: IconButton(
onPressed: () => Navigator.push(
context,
MaterialPageRoute<void>(
builder: (context) => CropPage(controller: _controller),
),
),
icon: const Icon(Icons.crop),
tooltip: 'Open crop screen',
),
),
const VerticalDivider(endIndent: 22, indent: 22),
Expanded(
child: PopupMenuButton(
tooltip: 'Open export menu',
icon: const Icon(Icons.save),
itemBuilder: (context) => [
PopupMenuItem(
onTap: _exportCover,
child: const Text('Export cover'),
),
PopupMenuItem(
onTap: _exportVideo,
child: const Text('Export video'),
),
],
),
),
],
),
),
);
}
String formatter(Duration duration) => [
duration.inMinutes.remainder(60).toString().padLeft(2, '0'),
duration.inSeconds.remainder(60).toString().padLeft(2, '0'),
].join(":");
List<Widget> _trimSlider() {
return [
AnimatedBuilder(
animation: Listenable.merge([
_controller,
_controller.video,
]),
builder: (_, __) {
final int duration = _controller.videoDuration.inSeconds;
final double pos = _controller.trimPosition * duration;
return Padding(
padding: EdgeInsets.symmetric(horizontal: height / 4),
child: Row(
children: [
Text(formatter(Duration(seconds: pos.toInt()))),
const Expanded(child: SizedBox()),
AnimatedOpacity(
opacity: _controller.isTrimming ? 1 : 0,
duration: kThemeAnimationDuration,
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Text(formatter(_controller.startTrim)),
const SizedBox(width: 10),
Text(formatter(_controller.endTrim)),
],
),
),
],
),
);
},
),
Container(
width: MediaQuery.of(context).size.width,
margin: EdgeInsets.symmetric(vertical: height / 4),
child: TrimSlider(
controller: _controller,
height: height,
horizontalMargin: height / 4,
child: TrimTimeline(
controller: _controller,
padding: const EdgeInsets.only(top: 10),
),
),
),
];
}
Widget _coverSelection() {
return SingleChildScrollView(
child: Center(
child: Container(
margin: const EdgeInsets.all(15),
child: CoverSelection(
controller: _controller,
size: height + 10,
quantity: 8,
selectedCoverBuilder: (cover, size) {
return Stack(
alignment: Alignment.center,
children: [
cover,
Icon(
Icons.check_circle,
color: const CoverSelectionStyle().selectedBorderColor,
),
],
);
},
),
),
),
);
}
}

View File

@@ -0,0 +1,67 @@
import 'package:flutter/material.dart';
import "package:photos/ui/tools/editor/video_editor/video_editor_bottom_action.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_main_actions.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_navigation_options.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_player_control.dart";
import 'package:video_editor/video_editor.dart';
class VideoRotatePage extends StatelessWidget {
const VideoRotatePage({super.key, required this.controller});
final VideoEditorController controller;
@override
Widget build(BuildContext context) {
final rotation = controller.rotation;
return Scaffold(
backgroundColor: Colors.black,
body: SafeArea(
child: Column(
children: [
Expanded(
child: Hero(
tag: "video-editor-preview",
child: CropGridViewer.preview(
controller: controller,
),
),
),
VideoEditorPlayerControl(
controller: controller,
),
VideoEditorMainActions(
children: [
VideoEditorBottomAction(
label: "Left",
onPressed: () =>
controller.rotate90Degrees(RotateDirection.left),
icon: Icons.rotate_left,
),
const SizedBox(width: 40),
VideoEditorBottomAction(
label: "Right",
onPressed: () =>
controller.rotate90Degrees(RotateDirection.right),
icon: Icons.rotate_right,
),
],
),
const SizedBox(height: 40),
VideoEditorNavigationOptions(
secondaryText: "Done",
onPrimaryPressed: () {
while (controller.rotation != rotation) {
controller.rotate90Degrees(RotateDirection.left);
}
Navigator.pop(context);
},
onSecondaryPressed: () {
Navigator.pop(context);
},
),
],
),
),
);
}
}

View File

@@ -0,0 +1,80 @@
import 'package:flutter/material.dart';
import "package:photos/ui/tools/editor/video_editor/video_editor_navigation_options.dart";
import "package:photos/ui/tools/editor/video_editor/video_editor_player_control.dart";
import 'package:video_editor/video_editor.dart';
class VideoTrimPage extends StatefulWidget {
const VideoTrimPage({super.key, required this.controller});
final VideoEditorController controller;
@override
State<VideoTrimPage> createState() => _VideoTrimPageState();
}
class _VideoTrimPageState extends State<VideoTrimPage> {
final double height = 60;
@override
Widget build(BuildContext context) {
final minTrim = widget.controller.minTrim;
final maxTrim = widget.controller.maxTrim;
return Scaffold(
backgroundColor: Colors.black,
body: SafeArea(
child: Column(
children: [
Expanded(
child: Hero(
tag: "video-editor-preview",
child: CropGridViewer.preview(
controller: widget.controller,
),
),
),
VideoEditorPlayerControl(
controller: widget.controller,
),
..._trimSlider(),
const SizedBox(height: 40),
VideoEditorNavigationOptions(
secondaryText: "Done",
onPrimaryPressed: () {
// reset trim
widget.controller.updateTrim(minTrim, maxTrim);
Navigator.pop(context);
},
onSecondaryPressed: () {
// WAY 1: validate crop parameters set in the crop view
widget.controller.applyCacheCrop();
// WAY 2: update manually with Offset values
// controller.updateCrop(const Offset(0.2, 0.2), const Offset(0.8, 0.8));
Navigator.pop(context);
},
),
],
),
),
);
}
List<Widget> _trimSlider() {
return [
Container(
width: MediaQuery.of(context).size.width,
margin: EdgeInsets.symmetric(vertical: height / 4, horizontal: 20),
child: TrimSlider(
controller: widget.controller,
height: height,
horizontalMargin: height / 4,
),
),
];
}
String formatter(Duration duration) => [
duration.inMinutes.remainder(60).toString().padLeft(2, '0'),
duration.inSeconds.remainder(60).toString().padLeft(2, '0'),
].join(":");
}

View File

@@ -151,66 +151,59 @@ class FileBottomBarState extends State<FileBottomBar> {
return ValueListenableBuilder(
valueListenable: widget.enableFullScreenNotifier,
builder: (BuildContext context, bool isFullScreen, _) {
return IgnorePointer(
ignoring: isFullScreen,
child: AnimatedOpacity(
opacity: isFullScreen ? 0 : 1,
duration: const Duration(milliseconds: 150),
child: Align(
alignment: Alignment.bottomCenter,
child: Container(
decoration: BoxDecoration(
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
colors: [
Colors.transparent,
Colors.black.withOpacity(0.6),
Colors.black.withOpacity(0.72),
],
stops: const [0, 0.8, 1],
return Align(
alignment: Alignment.bottomCenter,
child: Container(
decoration: BoxDecoration(
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
colors: [
Colors.transparent,
Colors.black.withOpacity(0.6),
Colors.black.withOpacity(0.72),
],
stops: const [0, 0.8, 1],
),
),
child: Padding(
padding: EdgeInsets.only(bottom: safeAreaBottomPadding),
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
widget.file.caption?.isNotEmpty ?? false
? Padding(
padding: const EdgeInsets.fromLTRB(
16,
12,
16,
0,
),
child: GestureDetector(
onTap: () async {
await _displayDetails(widget.file);
await Future.delayed(
const Duration(milliseconds: 500),
); //Waiting for some time till the caption gets updated in db if the user closes the bottom sheet without pressing 'done'
safeRefresh();
},
child: Text(
widget.file.caption!,
overflow: TextOverflow.ellipsis,
maxLines: 1,
style: getEnteTextTheme(context)
.mini
.copyWith(color: textBaseDark),
textAlign: TextAlign.center,
),
),
)
: const SizedBox.shrink(),
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: children,
),
),
child: Padding(
padding: EdgeInsets.only(bottom: safeAreaBottomPadding),
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
widget.file.caption?.isNotEmpty ?? false
? Padding(
padding: const EdgeInsets.fromLTRB(
16,
12,
16,
0,
),
child: GestureDetector(
onTap: () async {
await _displayDetails(widget.file);
await Future.delayed(
const Duration(milliseconds: 500),
); //Waiting for some time till the caption gets updated in db if the user closes the bottom sheet without pressing 'done'
safeRefresh();
},
child: Text(
widget.file.caption!,
overflow: TextOverflow.ellipsis,
maxLines: 1,
style: getEnteTextTheme(context)
.mini
.copyWith(color: textBaseDark),
textAlign: TextAlign.center,
),
),
)
: const SizedBox.shrink(),
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: children,
),
],
),
),
],
),
),
),

View File

@@ -928,6 +928,14 @@ packages:
url: "https://pub.dev"
source: hosted
version: "0.6.2"
flutter_svg:
dependency: "direct main"
description:
name: flutter_svg
sha256: "7b4ca6cf3304575fe9c8ec64813c8d02ee41d2afe60bcfe0678bcb5375d596a2"
url: "https://pub.dev"
source: hosted
version: "2.0.10+1"
flutter_test:
dependency: "direct dev"
description: flutter
@@ -2476,6 +2484,30 @@ packages:
url: "https://pub.dev"
source: hosted
version: "3.0.7"
vector_graphics:
dependency: transitive
description:
name: vector_graphics
sha256: "32c3c684e02f9bc0afb0ae0aa653337a2fe022e8ab064bcd7ffda27a74e288e3"
url: "https://pub.dev"
source: hosted
version: "1.1.11+1"
vector_graphics_codec:
dependency: transitive
description:
name: vector_graphics_codec
sha256: c86987475f162fadff579e7320c7ddda04cd2fdeffbe1129227a85d9ac9e03da
url: "https://pub.dev"
source: hosted
version: "1.1.11+1"
vector_graphics_compiler:
dependency: transitive
description:
name: vector_graphics_compiler
sha256: "12faff3f73b1741a36ca7e31b292ddeb629af819ca9efe9953b70bd63fc8cd81"
url: "https://pub.dev"
source: hosted
version: "1.1.11+1"
vector_math:
dependency: transitive
description:

View File

@@ -90,6 +90,7 @@ dependencies:
flutter_secure_storage: ^8.0.0
flutter_sodium: ^0.2.0
flutter_staggered_grid_view: ^0.6.2
flutter_svg: ^2.0.10+1
fluttertoast: ^8.0.6
fraction: ^5.0.2
freezed_annotation: ^2.4.1
@@ -238,6 +239,7 @@ flutter:
- assets/models/mobilenet/
- assets/models/scenes/
- assets/models/clip/
- assets/video-editor/
fonts:
- family: Inter
fonts: