npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-chat-vacancy-widget

v1.2.0

Published

A React widget for chat and vacancy management with customizable theme and token-based authentication

Downloads

4

Readme

react-chat-vacancy-widget

A customizable React widget for chat and vacancy management with token-based authentication and plain CSS styling. This widget allows users to interact with a chat interface, view job vacancies, upload resumes, and download generated files.

O‘zbekcha: Ushbu loyiha token asosidagi autentifikatsiya bilan chat va vakansiya boshqaruvi uchun moslashtiriladigan React vidjetini taqdim etadi. Tailwind CSS o‘rniga oddiy CSS ishlatilgan.

Features

Chat Interface: Send and receive messages with a typing animation and system messages.

Vacancy Management: Display job vacancies with expandable details and apply options.

File Upload: Upload PDF resumes for job applications.

File Download: Download generated files from the server.

Customizable Styling: Uses plain CSS for styling, fully customizable via props.

Positioning: Configurable widget position (e.g., bottom-right, top-left).

TypeScript Support: Fully typed with TypeScript for better developer experience.

Responsive Design: Adapts to different screen sizes with customizable width and height.

O‘zbekcha: Chat interfeysi, vakansiya ko‘rsatish, PDF rezume yuklash, fayl yuklab olish, moslashtiriladigan CSS va TypeScript qo‘llab-quvvatlash kabi xususiyatlar mavjud.

Installation

To use the widget in your React project, install it via npm:

npm install react-chat-vacancy-widget

O‘zbekcha: Vidjetni React loyihangizda ishlatish uchun npm orqali o‘rnating.

Usage

Import the WidgetComponent and the associated CSS file into your React application. Below is an example of how to integrate the widget:

import React from 'react'; import { WidgetComponent } from 'react-chat-vacancy-widget'; import 'react-chat-vacancy-widget/dist/styles.css';

const App: React.FC = () => { const handleWidgetReady = () => { console.log('Widget loaded!'); };

return ( My Application ); };

export default App;

Props:

token (string, required): Authentication token for API requests.

theme (string, optional): Primary color for the widget (hex code, default: #2563eb).

siteName (string, optional): Company name displayed in the widget header (default: "Kompaniya").

enableLogging (boolean, optional): Enable console logging for debugging (default: false).

position (string, optional): Widget position on the screen ("bottom-right", "bottom-left", "top-right", "top-left", default: "bottom-right").

width (string, optional): Widget width (e.g., "400px", default: "370px").

height (string, optional): Widget height (e.g., "600px", default: "500px").

onReady (function, optional): Callback function triggered when the widget is fully loaded.

O‘zbekcha: Vidjetni ishlatish uchun WidgetComponent ni va CSS faylini import qiling. Yuqoridagi misolda token, theme, siteName va boshqa props’lar orqali sozlash ko‘rsatilgan.

Project Structure

react-chat-vacancy-widget/ ├── src/ │ ├── index.tsx # Entry point for exports │ ├── WidgetComponent.tsx # Main widget component │ ├── LoadingSpinner.tsx # Loading spinner component │ ├── types.ts # TypeScript type definitions │ ├── styles.css # Plain CSS styles ├── package.json # Project metadata and dependencies ├── rollup.config.js # Rollup configuration for bundling ├── tsconfig.json # TypeScript configuration

Development Setup

To set up the project for development:

Clone the Repository (if applicable):

git clone cd react-chat-vacancy-widget

Install Dependencies:

npm install

Build the Project:

npm run build

This generates the dist folder with CommonJS (dist/cjs/index.js), ES Module (dist/esm/index.js), CSS (dist/styles.css), and TypeScript declaration (dist/index.d.ts) files.

Publish to npm (if you’re the maintainer):

npm login npm publish

Note: Ensure the name in package.json is unique (e.g., @xursandbekdev/react-chat-vacancy-widget).

O‘zbekcha: Loyihani ishlab chiqish uchun yuqoridagi qadamlar orqali loyihani sozlang, build qiling va npm’ga nashr qiling.

Dependencies

Production:

lucide-react: For icons used in the widget.

react and react-dom (peer dependencies): Required in the consuming project.

Development:

@rollup/plugin-commonjs

@rollup/plugin-node-resolve

@rollup/plugin-typescript

rollup

rollup-plugin-dts

rollup-plugin-peer-deps-external

rollup-plugin-postcss

typescript

@types/react

@types/react-dom

API Integration

The widget interacts with the following API endpoints:

Chat API: https://chatai.my-blog.uz/webhook/{token} (POST)

Upload API: ${VITE_API_URL}/upload/ (POST)

Vacancy API: ${VITE_API_URL}/vakansiya/ (GET)

Download API: ${VITE_API_URL}/download/{filename} (GET)

Ensure the token prop is valid for authentication with the chat API.

O‘zbekcha: Vidjet API’lar bilan ishlash uchun token to‘g‘ri bo‘lishi kerak. Yuqoridagi endpoint’lar chat, fayl yuklash, vakansiya olish va fayl yuklab olish uchun ishlatiladi.

Styling

The widget uses plain CSS (no Tailwind) defined in src/styles.css. The CSS is bundled into dist/styles.css and must be imported in the consuming application (see Usage section). Customize styles by modifying src/styles.css before building.

O‘zbekcha: Vidjet Tailwind’siz oddiy CSS’dan foydalanadi. Uslublarni src/styles.css faylida o‘zgartirish mumkin.

Troubleshooting

Build Errors: If you encounter build issues, ensure all dependencies are installed and src/styles.css has no syntax errors. Run npm install and check rollup.config.js.

CSS Not Applied: Ensure import 'react-chat-vacancy-widget/dist/styles.css'; is included in your application.

API Errors: Verify the token prop and API endpoint availability. Enable enableLogging={true} to debug API issues in the console.

Windows Terminal: Use cls instead of clear to clear the Command Prompt.

O‘zbekcha: Muammolar bo‘lsa, bog‘liqliklarni tekshiring, CSS faylida xatolik yo‘qligiga ishonch hosil qiling va enableLogging ni yoqing.

Contributing

Contributions are welcome! Please submit a pull request or open an issue on the repository for bug reports or feature requests. License MIT License

O‘zbekcha: Loyiha MIT litsenziyasi ostida tarqatiladi.