diff --git a/static/public/images/setting-up-sharex/import-url-shortener.png b/static/public/images/setting-up-sharex/import-url-shortener.png new file mode 100644 index 0000000..3fed632 Binary files /dev/null and b/static/public/images/setting-up-sharex/import-url-shortener.png differ diff --git a/static/public/images/setting-up-sharex/open-destination-settings.png b/static/public/images/setting-up-sharex/open-destination-settings.png new file mode 100644 index 0000000..8b21fc0 Binary files /dev/null and b/static/public/images/setting-up-sharex/open-destination-settings.png differ diff --git a/static/public/images/setting-up-sharex/set-default-shortener.png b/static/public/images/setting-up-sharex/set-default-shortener.png new file mode 100644 index 0000000..428b059 Binary files /dev/null and b/static/public/images/setting-up-sharex/set-default-shortener.png differ diff --git a/static/src/ShareX/ShareX.js b/static/src/ShareX/ShareX.js index d198bc6..6fe4f85 100644 --- a/static/src/ShareX/ShareX.js +++ b/static/src/ShareX/ShareX.js @@ -1,5 +1,5 @@ import React, { Component } from 'react' -import { Container } from 'semantic-ui-react' +import { Container, Image, Modal, Button, Icon } from 'semantic-ui-react' import ClipboardButton from 'react-clipboard.js'; import 'prismjs' import 'prismjs/components/prism-json' @@ -21,20 +21,61 @@ export default class ShareXComponent extends Component { }, ResponseType: "Text", URL: "$json:URL$" - }, null, 4) + }, null, 4), + currentStep: 0, + availableSteps: [ + { + image: "open-destination-settings.png", + text: "To add the correct configuration for the custom URL shortener in ShareX, open first the destination settings." + }, + { + image: "import-url-shortener.png", + text: "After you scroll down in the left sidebar, select custom uploaders. There you can import it from the clipboard." + }, + { + image: "set-default-shortener.png", + text: "Now it is successfully added to ShareX. To set it as the default shortener, select Custom URL shortener in the dropdown menu." + }, + ] } + goBackwards = () => this.setState({ currentStep: this.state.currentStep - 1 }) + + goForwards = () => this.setState({ currentStep: this.state.currentStep + 1 }) + render() { - const { config } = this.state + const { config, currentStep, availableSteps } = this.state return ( -
ShareX
+
On this page you see information about the ShareX integration and how you configure it. If you haven't ShareX installed, you can download it from here.
{config} - - Copy the configuration to the clipboard - + + + Copy the configuration and start the ShareX setup + + + }> + Setting up ShareX - Step {currentStep + 1} + +

{availableSteps[currentStep].text}

+ +
+ + {currentStep - 1 >= 0 && + + } + {currentStep + 1 < availableSteps.length && + + } + +
) }