Coder Social home page Coder Social logo

seals's Introduction

已失效,API 已被关闭

Seals

Seals 一个 electron/vue 小练手,它能帮你备份在 QQ 云端的聊天记录。

使用前你要需要

  • QQ 会员
  • 漫游全部好友
  • 下载最新的 releases

怎么使用

  • 打开 electron 后,将 seals.asar 拖进窗口
  • npm install electron-prebuilt -g > electron seals.asar

保存细节

数据使用 sqlite 保存,图片保存在 media 文件夹下

表结构

CREATE TABLE message ("time" DATETIME, "from" INT, "to" INT, "content" TEXT, " media" TEXT)
  • time unix 时间戳
  • from 发送人
  • to 接受人
  • content 消息内容,JSON 数组
  • media JSON 对象,保存原始 media 数据(一般无需读取)

消息类型

  • 0 文字
  • 1 QQ 自带表情(URL)
  • 2 URL 图片 / 自定义表情(失效图片)
  • 3 UUID 图片 / 自定义表情(默认会下载到 media 目录)

解析伪代码

let text = []
for (const slice of content) {
  switch (slice.type) {
    case 0:
      text.push(slice.value)
      break
    case 1:
      text.push(`<img src="${slice.value}">`)
      break
    case 2:
      text.push('[失效图片]')
      break
    case 3:
      // 已保存的图片
      text.push('<img src="./media/${slice.value}">')
      break
    default:
      break
  }
}

TODO

  • 偷懒的动画 or 图标补上
  • 用 vuex 重构 妈的没看到
  • webpack 热重载莫名工作不能...
  • 自动化 release

License

MIT

seals's People

Contributors

17 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

seals's Issues

能否请教一下,这些URL和参数是怎么获取的。

在这里提issues可能有点冒昧,但是又没有您其他联系方式。但是我觉得您这样获取聊天记录好高端,我也想做一个类似的功能。但是按照您代码的URL方式实验了一下,一直没有成功。不知道您能否告知是如何获取这些请求的URL的?使用什么工具或者方法。感激不尽。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.