dream-num / univer

Univer is an open-source alternative to Google Sheets, Slides, and Docs
https://univer.ai
Apache License 2.0
5.68k stars 469 forks source link

[Feature] It is expected that users can listen to the events of permission detection and customize the subsequent operations after the detection is completed. #2615

Closed TheMaximumPotential closed 6 days ago

TheMaximumPotential commented 1 week ago

初始清单

问题

现在不能自定义无权限弹框

解决方案

  1. 能有个地方传入回调函数在权限检测后执行。
  2. 可以监听到权限检测的事件,并且可以在参数中提供默认弹框的callback,可选执行。
univer-bot[bot] commented 1 week ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

Origin Title: [Feature] 期望用户可以监听到权限检测的事件并自定义检测完成的后续操作

Title: [Feature] It is expected that users can listen to the events of permission detection and customize the subsequent operations after the detection is completed.


Initial list

question

It is now impossible to customize the unauthorized pop-up box

solution

  1. There can be a place to pass in the callback function to be executed after permission detection.
  2. You can monitor permission detection events, and provide the callback of the default pop-up box in the parameters, which can be optionally executed.
ybzky commented 6 days ago

初始清单

  • [x] 这真的是个问题吗?
  • [x] 我已经在 Github Issues 中搜索过了,但没有找到类似的问题。

问题

现在不能自定义无权限弹框

解决方案

  1. 能有个地方传入回调函数在权限检测后执行。
  2. 可以监听到权限检测的事件,并且可以在参数中提供默认弹框的callback,可选执行。

你可以自己写一个插件 将权限的弹窗dispose掉,然后自己注册一个新的dialog进去

univer-bot[bot] commented 6 days ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿

Initial list

  • [x] Is this really a problem?
  • [x] I have searched Github Issues but found no similar issues.

Question

It is now impossible to customize the unauthorized pop-up box

Solution

  1. There can be a place to pass in the callback function to be executed after permission detection.
  2. You can monitor permission detection events, and provide the callback of the default pop-up box in the parameters, which can be optionally executed.

You can write a plug-in to dispose the permission pop-up window, and then register a new dialog yourself.