New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@deviniti/jql-autocomplete-input

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@deviniti/jql-autocomplete-input

Jira JQL autocomplete component based on the Atlaskit

  • 2.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
39
increased by30%
Maintainers
1
Weekly downloads
 
Created
Source

#Jira JQLAutocomplete input component

Getting started

Example

import React from 'react';
import axios from 'axios';
import JQLAutocompleteInput from '@deviniti/jql-autocomplete-input/dist/JQLAutocompleteInput';


class App extends React.Component {

    state = {
        inputValue: ''
    }

    fetchByAxios(resourceUrl) {
        return axios.get(resourceUrl);
    }

    getSuggestionsRequest = (fieldName, fieldValue)=> fetchByAxios(`/rest/api/2/jql/autocompletedata/suggestions?fieldName=${fieldName}&fieldValue=${fieldValue}`);

    validationRequest = jql => fetchByAxios(`/rest/api/2/search?startAt=0&maxResults=1&validateQuery=strict&fields=summary&jql=${jql}`);

    getAutocompleteDataRequest = () => fetchByAxios('/rest/api/2/jql/autocompletedata');

    onJQLChange = (event) => {
        this.setState({
            inputValue: event.target.value
        })
    };

	render() {
		return (
            <JQLAutocompleteInput
                getAutocompleteDataRequest={this.getAutocompleteDataRequest}
                getSuggestionsRequest={this.getSuggestionsRequest}
                inputStyle="ak-field-text"
                initialValue={this.props.inputValue}
                inputId={this.props.inputId}
                label={'JQL'}
                onChange={this.onJQLChange}
                setValue={this.props.setValue}
                validationRequest={this.validationRequest}
        />
		);
	}
}

Demo

Just open demo/index.html in your browser.

Changelog

v1.0.0

  • created

1.0.8

  • readme update

Keywords

FAQs

Package last updated on 13 Nov 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc