/* */

/* eslint-disable no-bitwise, no-cond-assign */

/* eslint-disable no-return-assign */

/* harmony default export */

/* harmony export (binding) */

/* harmony import */

/*#__PURE__*/

/**
 * A convenience hook around `useState` designed to be paired with
 * the component [callback ref](https://reactjs.org/docs/refs-and-the-dom.html#callback-refs) api.
 * Callback refs are useful over `useRef()` when you need to respond to the ref being set
 * instead of lazily accessing it in an effect.
 *
 * ```ts
 * const [element, attachRef] = useCallbackRef<HTMLDivElement>()
 *
 * useEffect(() => {
 *   if (!element) return
 *
 *   const calendar = new FullCalendar.Calendar(element)
 *
 *   return () => {
 *     calendar.destroy()
 *   }
 * }, [element])
 *
 * return <div ref={attachRef} />
 * ```
 *
 * @category refs
 */

/**
 * An `addEventListener` ponyfill, supports the `once` option
 */

/**
 * Creates a `Ref` whose value is updated in an effect, ensuring the most recent
 * value is the one rendered with. Generally only required for Concurrent mode usage
 * where previous work in `render()` may be discarded befor being used.
 *
 * This is safe to access in an event handler.
 *
 * @param value The `Ref` value
 */

/**
 * Store the last of some value. Tracked via a `Ref` only updating it
 * after the component renders.
 *
 * Helpful if you need to compare a prop value to it's previous value during render.
 *
 * ```ts
 * function Component(props) {
 *   const lastProps = usePrevious(props)
 *
 *   if (lastProps.foo !== props.foo)
 *     resetValueFromProps(props.foo)
 * }
 * ```
 *
 * @param value the value to track
 */

/**
 * Track whether a component is current mounted. Generally less preferable than
 * properlly canceling effects so they don't run after a component is unmounted,
 * but helpful in cases where that isn't feasible, such as a `Promise` resolution.
 *
 * @returns a function that returns the current isMounted state of the component
 *
 * ```ts
 * const [data, setData] = useState(null)
 * const isMounted = useMounted()
 *
 * useEffect(() => {
 *   fetchdata().then((newData) => {
 *      if (isMounted()) {
 *        setData(newData);
 *      }
 *   })
 * })
 * ```
 */

/**
* @license Apache-2.0
*
* Copyright (c) 2018 The Stdlib Authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*    http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* Capitalize the first character in a string.
*
* @module @stdlib/string/capitalize
*
* @example
* var capitalize = require( '@stdlib/string/capitalize' );
*
* var out = capitalize( 'last man standing' );
* // returns 'Last man standing'
*
* out = capitalize( 'Hidden Treasures' );
* // returns 'Hidden Treasures';
*/

/**
* Capitalizes the first character in a string.
*
* @param {string} str - input string
* @throws {TypeError} must provide a string primitive
* @returns {string} capitalized string
*
* @example
* var out = capitalize( 'last man standing' );
* // returns 'Last man standing'
*
* @example
* var out = capitalize( 'presidential election' );
* // returns 'Presidential election'
*
* @example
* var out = capitalize( 'javaScript' );
* // returns 'JavaScript'
*
* @example
* var out = capitalize( 'Hidden Treasures' );
* // returns 'Hidden Treasures'
*/

/**
* The **News** component scans the public **News API** (consisting of 71 international  newspapers) and displays the latest 10 articles of the given newspaper. There are two ways to enter a source: one by typing into the search field and submitting via the ENTER button, the second via voice.
*
* @property {boolean} invisible - indicates whether to show the input fields or rely solely on voice control to be triggered
* @property {string} key - authentication key for the News API
* @property {string} language - language identifier
* @property {string} voiceID - voice control identifier
* @property {Function} onArticles - callback function invoked with an array of article objects once they are received
*/

/***/

// EXPORTS //

// Exports

// FUNCTIONS //

// HTML DOM and SVG DOM may have different support levels,

// MAIN //

// MODULES //

// Module

// PROPERTIES //

// VARIABLES //

// eslint-disable-next-line no-multi-assign

// so we need to check on context instead of a document root element.
