<commit_before>namespace $.$$ {
	export class $mol_embed_native extends $.$mol_embed_native {

		@ $mol_mem
		window() {
			return $mol_wire_sync( this as $mol_embed_native ).load( this.dom_node() as HTMLIFrameElement, this.uri_resource() )
		}
		
		load( frame: HTMLIFrameElement, uri: string ) {
			return new Promise< Window >( ( done, fail )=> {
				
				new $mol_after_timeout( 3_000, ()=> {
					try {
						if( frame.contentWindow!.location.href === 'about:blank' ) {
							done( frame.contentWindow! )
						}
					} catch { }
				} )
				
				frame.onload = () => {
					done( frame.contentWindow! )
				}
				
				frame.onerror = ( event : Event | string ) => {
					fail( typeof event === 'string' ? new Error( event ) : ( event as ErrorEvent ).error || event )
				}
				
			} )
		}<commit_msg>$mol_embed_native: better track loading<commit_after>namespace $.$$ {
	export class $mol_embed_native extends $.$mol_embed_native {

		@ $mol_mem
		window() {
			this.uri()
			return $mol_wire_sync( this as $mol_embed_native ).load( this.dom_node() as HTMLIFrameElement, this.uri_resource() )
		}
		
		load( frame: HTMLIFrameElement, uri: string ) {
			return new Promise< Window >( ( done, fail )=> {
				
				frame.onload = () => {
					try {
						if( frame.contentWindow!.location.href === 'about:blank' ) {
							return
						}
					} catch { }
					done( frame.contentWindow! )
				}
				
				frame.onerror = ( event : Event | string ) => {
					fail( typeof event === 'string' ? new Error( event ) : ( event as ErrorEvent ).error || event )
				}
				
			} )
		}
{'fraction_non_alphanumeric': 0.14774889029803423, 'fraction_numerical': 0.0025364616360177552, 'mean_word_length': 2.5863636363636364, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3682785', 'n_tokens_mistral': 684, 'n_tokens_neox': 509, 'n_words': 116}