Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ serverless_wsgi.py
.elasticbeanstalk/*
!.elasticbeanstalk/*.cfg.yml
!.elasticbeanstalk/*.global.yml
extension
#extension
extension/dist
extension/build
11 changes: 11 additions & 0 deletions extension/.babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
// Only used when compiling extension or functions
"presets": ["@babel/env", "@babel/preset-typescript", "@babel/preset-react"],
"plugins": [
// Supress storybook warnings, but may also affect how NextJS generates code
["@babel/plugin-proposal-class-properties", { "loose": true }],
["@babel/plugin-proposal-private-methods", { "loose": true }],
["@babel/plugin-proposal-private-property-in-object", { "loose": true }],
["@babel/transform-runtime", { "useESModules": false }]
]
}
6 changes: 6 additions & 0 deletions extension/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
build
node_modules
.DS_Store
.vscode
extension-stats.json
dist
1 change: 1 addition & 0 deletions extension/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
src/GlobalStyle.tsx
19 changes: 19 additions & 0 deletions extension/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Augmented AI

## Introduction

Browser extension platform.

Run powerful apps within your browser, unlocking limitless possibilities. Break through the limiting API and access data natively using extension. Quickly build new functions for existing platforms.

## Development

```
npm i
# Run in one terminal development build of the extension
NEXT_PUBLIC_API_URL=http://localhost:3000 npm run ext:dev
# Run in other terminal API server
OPENAI_API_KEY=skaaa npm run dev
```

Install the extension in your browser from the build folder.
7 changes: 7 additions & 0 deletions extension/images/gen.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash
N="16 32 64 128 256"
rm *.png
for S in $N; do
echo "Convert to ${S}x${S}"
convert -background none icon.svg icon-${S}x${S}.png
done
Binary file added extension/images/icon-128x128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added extension/images/icon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added extension/images/icon-256x256.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added extension/images/icon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added extension/images/icon-64x64.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions extension/images/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions extension/install.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="utf-8" />
<title>Article AI extension</title>
<meta name="viewport" content="width=device-width,initial-scale=1" />
<meta name="version" value="$VERSION.$BUILD_NUMBER" />
<style>
html,
body {
margin: 0px;
padding: 0px;
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica,
"Apple Color Emoji", Arial, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
-webkit-font-smoothing: auto;
background-color: #092340;
color: #fff;
}
</style>
</head>

<body id="install">
<div>
<div id="react"></div>
</div>
<script src="util/popup-fix.js"></script>
<script src="src/install.js"></script>
</body>

</html>
43 changes: 43 additions & 0 deletions extension/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"manifest_version": 2,
"name": "Extension",
"short_name": "test-extension",
"version": "$VERSION.$BUILD_NUMBER",
"author": "Ruslan Gainutdinov <ruslan@wizecore.com>",
"description": "Browser extension automation platform. Run on theguardian.com, twitter.com, linkedin.com, booking.com",
"homepage_url": "https://github.com/huksley/article-ai",

"browser_action": {
"default_icon": {
"16": "images/icon-16x16.png",
"32": "images/icon-32x32.png",
"64": "images/icon-64x64.png",
"128": "images/icon-128x128.png",
"256": "images/icon-256x256.png"
},
"default_title": "Extension",
"default_popup": "popup.html"
},

"icons": {
"16": "images/icon-16x16.png",
"32": "images/icon-32x32.png",
"64": "images/icon-64x64.png",
"128": "images/icon-128x128.png",
"256": "images/icon-256x256.png"
},

"background": {
"scripts": ["src/background.js"]
},

"content_scripts": [
{
"js": ["src/boot.js"],
"run_at": "document_start"
}
],

"web_accessible_resources": ["src/*", "assets/*", "images/*", "util/*"],
"permissions": ["storage"]
}
Loading