react-grab 0.1.0-beta.7 → 0.1.0-beta.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import {k}from'./chunk-NK2BNSLR.js';export{j as DEFAULT_THEME,h as captureElementScreenshot,g as combineBounds,i as copyImageToClipboard,d as formatElementInfo,f as generateSnippet,c as getStack,k as init,b as isInstrumentationActive,a as isScreenshotSupported}from'./chunk-NK2BNSLR.js';/**
1
+ import {k}from'./chunk-JB7MX447.js';export{j as DEFAULT_THEME,h as captureElementScreenshot,g as combineBounds,i as copyImageToClipboard,d as formatElementInfo,f as generateSnippet,c as getStack,k as init,b as isInstrumentationActive,a as isScreenshotSupported}from'./chunk-JB7MX447.js';/**
2
2
  * @license MIT
3
3
  *
4
4
  * Copyright (c) 2025 Aiden Bai
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-grab",
3
- "version": "0.1.0-beta.7",
3
+ "version": "0.1.0-beta.9",
4
4
  "description": "Select context for coding agents directly from your website",
5
5
  "keywords": [
6
6
  "react",
@@ -52,9 +52,6 @@
52
52
  "./dist/*.cjs": "./dist/*.cjs",
53
53
  "./dist/*.mjs": "./dist/*.mjs"
54
54
  },
55
- "bin": {
56
- "react-grab": "./dist/cli.cjs"
57
- },
58
55
  "main": "dist/index.js",
59
56
  "module": "dist/index.js",
60
57
  "browser": "dist/index.global.js",
package/dist/cli.cjs DELETED
@@ -1,3 +0,0 @@
1
- #!/usr/bin/env node
2
- 'use strict';var child_process=require('child_process');var e="0.1.0-beta.7",t=`grab@${e}`,p=()=>{try{let r=child_process.execSync("grab --version",{encoding:"utf-8"}).match(/(\d+\.\d+\.\d+)/);return r?r[1]:null}catch{return null}},m=()=>{let n=p();return n?/^\d+\.\d+\.\d+$/.test(e)?n!==e:false:true},u=()=>{let n=["pnpm","yarn","bun"];for(let r of n)try{return child_process.execSync(`${r} --version`,{stdio:"ignore"}),r}catch{continue}return "npm"},b=()=>{let n=u(),r={npm:"npm install -g",yarn:"yarn global add",pnpm:"pnpm add -g",bun:"bun add -g"},l={npm:"npm install -D",yarn:"yarn add -D",pnpm:"pnpm add -D",bun:"bun add -D"},c=r[n],i=l[n];console.log(`Installing ${t}\u2026`),child_process.execSync(`${c} ${t}`,{stdio:"inherit"});try{child_process.execSync(`${i} ${t}`,{stdio:"pipe"});}catch(d){let a=d.stderr?.toString().trim();console.error(a?`Failed to install ${t} locally:
3
- ${a}`:`Failed to install ${t} locally`);}};m()&&b();var o=child_process.spawnSync("grab",process.argv.slice(2),{stdio:"inherit",shell:process.platform==="win32"});o.error&&(console.error(`Failed to execute grab: ${o.error.message}`),process.exit(1));process.exit(o.status??0);