Thereisnospon / NovelAiTag

56 stars 17 forks source link

readme文件命名错误导致首页看不到readme内容及一些其他建议 #15

Open KesaubeEire opened 1 year ago

KesaubeEire commented 1 year ago

感谢大佬 从 B站 来的, @西红噬土豆 是你吧 大佬这 typo 不应该吧哈哈哈哈笑死了 把你 READMD.md 改为 README.md, 不然首页看不到 readme 内容

其他建议

  1. 建议在 readme 里面写点你的B站或者其他信息什么的方便大家指路
  2. 另外不知道你会不会前端框架, 或者别的啥的, bootstrap 肯定是够用的, 但是可能也不是特别方便扩展功能
  3. 你的 index.js 里面的特殊实践可以像你把 magic_trans 和 magic_book 一样独立出来新的文件, 避免放在 index.js 里面造成语义混乱, 同时在 readme.md 里面写好每个文件的作用方便整理结构...不过这都是有时间就能搞的事情, 不做也不是不能用
Thereisnospon commented 1 year ago

😂前几天半小时速成的html和js, 第二天又速成了 bootstrap 。本来是想用 react + ant design 的。但是感觉学起来太慢了,还得搞 npm,webhook 一堆。就勉强这样嗯写了。 代码结构肯定都会调整的,不然到时候甩手的话其他人维护不了,关键还是最近太肝了,各种到处修修补补。

KesaubeEire commented 1 year ago

要不帮你搞搞, 现在的需求是啥写在 readme 里面, 分个工

Thereisnospon commented 1 year ago

可以的,你可以先整理下 readme ,拆分下 index.js 里的数据。然后提一个 pr .

KesaubeEire commented 1 year ago

OK

Thereisnospon commented 1 year ago

还有其他几个需求,其他人提到过的。你看你有时间做哪个不,或者有没有什么思路或者建议

  1. 怎样实现 tag 搜索功能。现在感觉不太好做。
  2. 迁移数据存储方式,比如用 InnoDB 或者文件存储,现在的 LocalStorage 好像存不了太多数据,而且容易被清理缓存。
  3. 如果你会其他前端框架的话,可以搭建一个骨架出来,不需要处理业务代码,我可以把业务迁移进去。主要是感觉搭建骨架学起来有点麻烦,搭完的话,我看api 文档应该很快能搞完
KesaubeEire commented 1 year ago

OK, 我先把第一个 pr 提了, 框架的话我只会 vue, 你觉得可以么

Thereisnospon commented 1 year ago

可以的。 这个之前还了解过一点点

KesaubeEire commented 1 year ago

OK

KesaubeEire commented 1 year ago
  1. 搜索功能不是特别好解决, 我只能想到用一些现成的方案, 比如 vue 官方文档那种方案
  2. localstorage 的问题是可以解决的, 以这个数据量来说完全用不到那些数据存储方式, vue 的状态管理是可以搞定的, 底层依然是 localstorage, 只是需要多封装几层, 这个好说
KesaubeEire commented 1 year ago

第一个修改 readme 的 pr 提过去了

KesaubeEire commented 1 year ago

你 index.html 里多写了一个

导致我格式化半天出不来

Thereisnospon commented 1 year ago

多写了啥

KesaubeEire commented 1 year ago

< \ div >

KesaubeEire commented 1 year ago

image 这部分的注释有点问题, 里面这部分是要还是不要

Thereisnospon commented 1 year ago

不需要

KesaubeEire commented 1 year ago

结构有点问题, 但是问题不大 你的逻辑应该是

  1. 第一行是各种站内站外宏观操作
  2. 第二行是 prompt tag 的整体操作
  3. 第三行是具体的 prompt tag 操作 对吧, 但是你的 html 结构有点乱, 如果我说的这个结构是正确的, 那我就加注释了, 结构不对你给我说下你的结构
Thereisnospon commented 1 year ago

没啥问题。 结构有很多都是因为不知道怎么右对齐,然后加个文本框把其它按钮顶到最右边。。。

KesaubeEire commented 1 year ago

那行, 那我整一整

KesaubeEire commented 1 year ago

不得不说, 你这个右对齐的思路非常nice

没啥问题。 结构有很多都是因为不知道怎么右对齐,然后加个文本框把其它按钮顶到最右边。。。

不得不说, 你这个思路非常, 非常, 巧

KesaubeEire commented 1 year ago

然后你的第一行的 input 顺序和展开的模块顺序是不一样的, 虽然无所谓, 但是真的很有意思哈哈哈

KesaubeEire commented 1 year ago

看了看, 还是用 ui 库吧, vue3ui大全 挑一个喜欢的吧

Thereisnospon commented 1 year ago

偏向于 element ,看上去现在用到的一些 Bootstrap 组件。在 element 都有

KesaubeEire commented 1 year ago

样式用 bootstrap 写在 js 里很不利与团队合作, 我能看懂但是改起来有点费事, 样式还是用 CSS 比较合适

Thereisnospon commented 1 year ago

这是因为要动态添加 element ,用的裸写的 js , 没用框架的 数据驱动的形式,一开始只是想做几个非常简单的页面,用着还行,后面功能越做越多就乱了。

KesaubeEire commented 1 year ago

OK, 我写了点注释结构的, 你看看怎么样 image

KesaubeEire commented 1 year ago

能看我就推 pr 然后重开去了

KesaubeEire commented 1 year ago

或者这样 image

Thereisnospon commented 1 year ago

感觉界面凌乱 不规则了很多。

KesaubeEire commented 1 year ago

是的, 主要是哪些标签的排列方式, 原先都是 左对齐, 现在居中了, 是一个 flex 的问题, 我看不懂你 bootstrap 里面怎么写的

Thereisnospon commented 1 year ago

你这个是用啥写的。能还原之前的样子吗

KesaubeEire commented 1 year ago

我只改了 index.html 我没动 index.js 里面的代码, 要不我推上去你再改

KesaubeEire commented 1 year ago

我还没有提交 pr , 现在谈不上改回原来的样子, 我这只是在本地的截图

KesaubeEire commented 1 year ago

你可以看看我的仓库版本

KesaubeEire commented 1 year ago

我找到问题在哪里了, 但是处理起来比较麻烦

Thereisnospon commented 1 year ago

为啥要改成 flex 呀 不能保留原有结构吗

KesaubeEire commented 1 year ago

你用了 bootstrap 的 container 是吧

Thereisnospon commented 1 year ago

是啊

KesaubeEire commented 1 year ago

这个, 本身 bootstrap 的 container 就是包裹的 flex

KesaubeEire commented 1 year ago

我觉得样式优先级比较低, 我找到了问题, 但是改起来有点痛苦, 所以我感觉, 我直接新开吧, 我把新开的写个差不多, 然后再和你合并

KesaubeEire commented 1 year ago

你觉得怎么样

Thereisnospon commented 1 year ago

用新框架实现ui吗。

KesaubeEire commented 1 year ago

对, 我直接用 vue3 + elementPlus 起一个没功能的页面, 然后你往里填功能

Thereisnospon commented 1 year ago

可以的👍🏻

KesaubeEire commented 1 year ago

你需要把 index.js 里的功能实现好好梳理一遍, 把公共方法提出来放在一块儿, 以功能为线索把每个区域 的方法用注释放在一起 , 每个按键的函数标记好, 这对之后的改动和整理都有帮助

Thereisnospon commented 1 year ago

不一定要完全一样,重要的tag操作不变,上面的几个菜单可以灵活优化下

Thereisnospon commented 1 year ago

Index晚上会整理,现在不在电脑边

KesaubeEire commented 1 year ago

行, 那你可以拿个软件画一下, 做个产品经理

KesaubeEire commented 1 year ago

你的 logo 用的是 icon.png 吧, 但是你还有个 logo.jpg, 是干啥用的

KesaubeEire commented 1 year ago

从你的网站标题上看应该是 魔法书更合适吧

Thereisnospon commented 1 year ago

这个可以先不管,到时候用ai生成一个图标