Amp 上线网站反馈组件,可在网页标注后生成修改线程
Amp 推出网站反馈组件,允许用户在网页上直接进行标注并向 Amp 发送修改指令。开发者在项目设置中启用该组件并向网页 head 标签添加脚本后,即可通过在网址后附加 ?amp 参数唤醒标注小部件,提交后 Amp 会自动在项目中创建新线程并生成修改。
You can now send feedback to Amp directly from your website.
Enable the feedback widget for your project and add one script to your website.
Then visit the site with ?amp appended, and the annotation widget is displayed.
Click on any part of the page and write instructions for Amp.
Once you are done, send the feedback to Amp. The first time, you sign in with Amp. Then Amp starts a new thread in your project and makes the change.
You ship it from the thread like any other change.
Set It Up
Open your project's settings and go to the Feedback Widget tab. Click Enable.
Then add the script to your site's <head>:
<script src="https://ampcode.com/w/client_01J….js" async></script>
Under Allowed Origins, add your site's address. The widget only works on the sites in that list.
Use It
By default the widget is invisible: it only shows up when you open the site with ?amp, or when you have used the widget before.
Click the widget, then click an element on the page and write what you want changed. Click New Comment to comment on another one.
When you're done, click Send. The first time, Amp asks you to connect your account: click Continue with Amp, sign in, and approve the consent screen.
Then click Start in Orb. Amp starts a new thread in your project with your comments, and Open Thread takes you there.
After that, the widget shows up on this site without ?amp, until you hide it.
Read more about the feedback widget in the docs.
来源:Amp Chronicle · ampcode.com